-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Open
Labels
T-bugType: bugType: bugT-to-discussType: requires discussionType: requires discussionT-to-investigateType: to investigateType: to investigate
Description
Component
Forge
Have you ensured that all of these are up to date?
- Foundry
- Foundryup
What version of Foundry are you on?
v1.3.5-nightly
What version of Foundryup are you on?
v1.3.0
What command(s) is the bug in?
forge build
Operating System
macOS (Apple Silicon)
Describe the bug
Bug Report
When the user remaps forge-std/=../node_modules/forge-std/src/
, but another dependency expects forge-std
to be remapped WITHOUT the /src/
path, the build fails.
In my case, this happens when I use the openzeppelin-foundry-upgrades dependency alongside my remappings
:
[profile.default]
remappings = [
"@chainlink/=../node_modules/@chainlink/",
"@openzeppelin/=../node_modules/@openzeppelin/",
"@prb/=../node_modules/@prb/",
"@sablier/=../node_modules/@sablier/",
"forge-std/=../node_modules/forge-std/",
"solady/=../node_modules/solady/",
]
Error Log
Error: Compiler run failed:
Error (6275): Source "../node_modules/forge-std/Vm.sol" not found: File not found. Searched the following locations: "/home/runner/work/evm-monorepo/evm-monorepo/utils".
ParserError: Source "../node_modules/forge-std/Vm.sol" not found: File not found. Searched the following locations: "/home/runner/work/evm-monorepo/evm-monorepo/utils".
--> ../node_modules/@openzeppelin/foundry-upgrades/src/Upgrades.sol:9:1:
|
9 | import {Vm} from "forge-std/Vm.sol";
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Repro
- Clone https://github.com/sablier-labs/evm-monorepo/tree/0f06c91b46b38f66c986780ac7736b61edcce0fb
- Run
bun install
cd utils
forge build
Related
Possibly related to #5447
Metadata
Metadata
Assignees
Labels
T-bugType: bugType: bugT-to-discussType: requires discussionType: requires discussionT-to-investigateType: to investigateType: to investigate
Type
Projects
Status
Backlog