You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+12-2Lines changed: 12 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -47,6 +47,16 @@ A code walkthrough is available [here](https://www.youtube.com/watch?v=EUl3UlYSl
47
47
48
48
Instructions for installing a development version of Slither can be found in our [wiki](https://github.com/crytic/slither/wiki/Developer-installation).
49
49
50
+
For development setup, we use [uv](https://github.com/astral-sh/uv):
51
+
52
+
```bash
53
+
# Install uv if you haven't already
54
+
curl -LsSf https://astral.sh/uv/install.sh | sh
55
+
56
+
# Setup development environment
57
+
make dev # Creates venv and installs all dependencies
58
+
```
59
+
50
60
To run the unit tests, you need to clone this repository and run `make test`. Run a specific test with `make test TESTS=$test_name`. The names of tests can be obtained with `pytest tests --collect-only`.
51
61
52
62
### Linters
@@ -111,9 +121,9 @@ For each new detector, at least one regression tests must be present.
111
121
112
122
### Synchronization with crytic-compile
113
123
114
-
By default, `slither` follows either the latest version of crytic-compile in pip, or `crytic-compile@master` (look for dependencies in [`setup.py`](./setup.py). If crytic-compile development comes with breaking changes, the process to update `slither` is:
124
+
By default, `slither` follows either the latest version of crytic-compile in pip, or `crytic-compile@master` (look for dependencies in [`pyproject.toml`](./pyproject.toml). If crytic-compile development comes with breaking changes, the process to update `slither` is:
115
125
116
-
- Update `slither/setup.py` to point to the related crytic-compile's branch
126
+
- Update `slither/pyproject.toml` to point to the related crytic-compile's branch
117
127
- Create a PR in `slither` and ensure it passes the CI
118
128
- Once the development branch is merged in `crytic-compile@master`, ensure `slither` follows the `master` branch
If you're **not** going to use one of the [supported compilation frameworks](https://github.com/crytic/crytic-compile), you need [solc](https://github.com/ethereum/solidity/), the Solidity compiler; we recommend using [solc-select](https://github.com/crytic/solc-select) to conveniently switch between solc versions.
72
73
74
+
### Using uv (Recommended)
75
+
76
+
[uv](https://github.com/astral-sh/uv) is a fast Python package manager that's 10-100x faster than pip.
We recommend using a Python virtual environment, as detailed in the [Developer Installation Instructions](https://github.com/crytic/slither/wiki/Developer-installation), if you prefer to install Slither via git.
125
+
The `-e` flag installs in editable mode, meaning changes to the source code are immediately reflected without reinstalling.
0 commit comments