-
Notifications
You must be signed in to change notification settings - Fork 553
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compiler remappings fails if same name path #893
Comments
the issue is in |
This is a hacky workaround
|
Thanks for the workaround, I'll have a look here shortly. For reference: https://docs.soliditylang.org/en/latest/using-the-compiler.html#path-remapping |
I have reproduced the same bug. I think can formalize it in the next way:
For example I have:
So both packages has the same
Issue reproduces with different order of packages, different imports, different truffle or solc versions. Brownie version 1.12.2 Though, issue does not reproduce, when I manually clone all the packages except the first ( |
Totally reproducing:
the above works, but if you remap as just
i.e. if 2 remappings have the same path prefix, it's compiler errors "File not found" all over the place, like
|
This worked for me:
|
Environment information
brownie
Version: 1.12.1ganache-cli
Version: x.x.xsolc
Version: x.x.xWhat was wrong?
brownie pm install OpenZeppelin/openzeppelin-contracts@2.5.1
brownie pm install uniswap/uniswap-v2-core@1.0.1
brownie pm install uniswap/uniswap-lib@2.1.0
If I flip the two uniswap remappings, the 2nd one always fails. eg)
will produce errors
How can it be fixed?
regex? it appears the remapping ignores the info after the
/
souniswap/lib
anduniswap/v2-core
are just treated identically. the 2nd entry will always fail.The text was updated successfully, but these errors were encountered: