Closed sjkelleyjr closed 7 months ago
Hi @sjkelleyjr,
Can you give a bit more context? Are you using a compilation framework (truffe/hardhat/...), or are you doing everything through solc directly?
I was using brownie. I ended up getting help and fixing a small bug in crytic-compile, but I'm still curious as to why this wasn't working, so I left the issue open. It might also be related to the other issue I opened that you responded to.
I am also running into this error:
slither ./contracts/Lending.sol --solc-remaps @openzeppelin/contracts=./node_modules/@openzeppelin/contracts;@chainlink/contracts=./node_modules/@chainlink/contracts --exclude naming-convention
and
slither ./contracts/Lending.sol --solc-remaps @openzeppelin/contracts=./node_modules/@openzeppelin/contracts,@chainlink/contracts=./node_modules/@chainlink/contracts --exclude naming-convention
Both miss the multiple imports
Hi @PatrickAlphaC. From looking at the code, --solc-remaps
expects space-separated remaps (so --solc-remaps "@foo=./bar @baz=./xyz"
)
Alternatively, you can use the slither config file and add a list of remappings there (solc_remaps: ["...", "..."]
)
This was perfect, thank you!!
slither ./contracts/ --solc-remaps '@openzeppelin/contracts=./node_modules/@openzeppelin/contracts @chainlink/contracts=./node_modules/@chainlink/contracts' --exclude naming-convention
I'm trying to run slither on some contracts, but need to remap multiple imports, when I try separating them with a semicolon, it doesn't pick up the second remapping. What is the appropriate syntax for remapping multiple imports using slither?