crytic / crytic/slither

optimize and make sure unused-imports is accurate

Open
#2,477 3 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
6.4k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

It was added in https://github.com/crytic/slither/pull/2392 but it is really slow and has some edge cases e.g.
this is wrong
```
The following unused import(s) in src/universal/CrossDomainMessenger.sol should be removed:
-import { Initializable } from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; (src/universal/CrossDomainMessenger.sol#4)
```
`slither contracts.zip --detect unused-import `
[contracts.zip](https://github.com/user-attachments/files/15597731/contracts.zip)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.