From 701f378e881e8f9545718aa9ee6ff6bdb46d211f Mon Sep 17 00:00:00 2001 From: Mark Tyneway Date: Sun, 5 May 2024 19:36:14 +0200 Subject: [PATCH] slither: bump ci versions Since slither seems to be failing consistently in CI, try bumping the versions of the tooling. Bumps to latest slither github action release: https://github.com/crytic/slither-action/releases/tag/v0.4.0 Meant to fix the slither issue seen in https://github.com/ethereum-optimism/optimism/pull/10408 ``` [-] SARIF output enabled, writing to results.sarif. [-] Slither config provided: packages/contracts-bedrock/slither.config.json [-] SLITHERARGS provided. Running slither with extra arguments 'forge clean' running (wd: /github/workspace/packages/contracts-bedrock) 'forge config --json' running 'forge build --build-info --skip */test/** */scripts/** --force' running (wd: /github/workspace/packages/contracts-bedrock) Traceback (most recent call last): File "/opt/slither/bin/slither", line 8, in sys.exit(main()) File "/opt/slither/lib/python3.9/site-packages/slither/__main__.py", line 753, in main main_impl(all_detector_classes=detectors, all_printer_classes=printers) File "/opt/slither/lib/python3.9/site-packages/slither/__main__.py", line 859, in main_impl ) = process_all(filename, args, detector_classes, printer_classes) File "/opt/slither/lib/python3.9/site-packages/slither/__main__.py", line 107, in process_all ) = process_single(compilation, args, detector_classes, printer_classes) File "/opt/slither/lib/python3.9/site-packages/slither/__main__.py", line 80, in process_single slither = Slither(target, ast_format=ast, **vars(args)) File "/opt/slither/lib/python3.9/site-packages/slither/slither.py", line 156, in __init__ sol_parser.parse_top_level_items(ast, path) File "/opt/slither/lib/python3.9/site-packages/slither/solc_parsing/slither_compilation_unit_solc.py", line 326, in parse_top_level_items get_imported_scope = self.compilation_unit.get_scope(import_directive.filename) File "/opt/slither/lib/python3.9/site-packages/slither/core/compilation_unit.py", line 282, in get_scope filename = self._crytic_compile_compilation_unit.crytic_compile.filename_lookup( File "/opt/slither/lib/python3.9/site-packages/crytic_compile/crytic_compile.py", line 283, in filename_lookup raise ValueError(f"{filename} does not exist") ValueError: lib/openzeppelin-contracts/contracts/utils/Context.sol does not exist ``` --- .github/workflows/slither.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/slither.yml b/.github/workflows/slither.yml index e63ba92ecccf..1c429701b3ab 100644 --- a/.github/workflows/slither.yml +++ b/.github/workflows/slither.yml @@ -11,7 +11,7 @@ jobs: slither-analyze: runs-on: ubuntu-latest container: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:v0.43.0 + image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:v0.48.0 steps: - uses: actions/checkout@v4 @@ -23,7 +23,7 @@ jobs: run: rm packages/contracts-bedrock/package.json - name: Run Slither - uses: crytic/slither-action@v0.3.2 + uses: crytic/slither-action@v0.4.0 id: slither with: target: packages/contracts-bedrock