报错提示:Error: Source file requires different compiler version (current compiler is 0.8.9+commit.e5eed63a.Linux.g++) - note that nightly builds are considered to be strictly less than the released version
中文翻译:错误:源文件需要不同的编译器版本(当前编译器为0.8.9+commit.e5eed63a.Linux.g++)-请注意,夜间版本被认为严格低于发布版本
本文使用的是trailofbits/eth-security-toolbox的docker镜像。
拉取安装命令为:
| 拉取镜像:docker pull trailofbits/eth-security-toolbox 挂载硬盘并运行:docker run -it -v /home/share:/share trailofbits/eth-security-toolbox |
查询slither版本:
| ethsec@1de8139f5251:~$ slither --version 0.8.3 |
查找solc命令所在位置:

本文介绍了在遇到智能合约源文件与当前solc编译器版本不兼容的错误时,如何利用Slither工具和solc-select进行版本管理。通过使用trailofbits/eth-security-toolbox Docker镜像,查询并设置solc版本,确保编译器版本匹配,从而解决错误。此外,还提供了Slither的批量和单文件检测用法。
最低0.47元/天 解锁文章

被折叠的 条评论
为什么被折叠?



