Repository navigation
test: Remove all-lint.py script - #29228
Conversation
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. Code CoverageFor detailed information about the code coverage, see the test coverage report. ReviewsSee the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update. |
|
looks like we can replace the comment to run all the lint commands we can swap this |
However, it is quite convenient to run |
Why would it be convenient, when it is called "all-lint", but at the same time skips checks such as the fs check, the subtree check, and the doc check? |
Chiming in as a very inexperienced contributor that has been bashing against CI linter failures: I would say it's very nice to have an easy way to run all tests and checks locally before pushing. The correct thing to do here would be to expand the linter script to include more of the checks, IMO. On a slightly related note: it would also be nice to include either instructions or CLI flags that fix linter complaints, where possible. I had issues with getting the whitespace linter to pass, and couldn't find any Makefile target, script or similar to automatically format my Python code. |
If you want to run all checks locally, you can refer to the documentation (https://github.com/bitcoin/bitcoin/blob/master/test/lint/README.md#running-locally). The options include running them in a docker container, or via the test_runner. I am happy to close this pull, but |
I think you can use any automated formatter of your choice. For example |
|
Concept ACK |
Can be reviewed with --color-moved=dimmed-zebra
fa9094a to
fa2b95c
Compare
Thanks, added a commit to move the documentation to one place. |
|
I use |
|
ACK fa2b95c |
pablomartin4btc
left a comment
There was a problem hiding this comment.
tACK fa2b95c
I also used to run the all-int.py but I've tried the docker linter locally following the instructions from the link provided in the description of the PR and I'll use that going forward.
DOCKER_BUILDKIT=1 docker build -t bitcoin-linter --file "./ci/lint_imagefile" ./ && docker run --rm -v $(pwd):/bitcoin -it bitcoin-linter
[+] Building 169.7s (12/12) FINISHED docker:default
=> [internal] load build definition from lint_imagefile 0.1s
=> => transferring dockerfile: 708B 0.0s
=> [internal] load .dockerignore 0.1s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for docker.io/library/debian:bookworm 2.9s
=> [1/7] FROM docker.io/library/debian:bookworm@sha256:b16cef8cbcb20935c0f052e37fc3d38dc92bfec0bcfb894c328547f81e932d67 3.3s
=> => resolve docker.io/library/debian:bookworm@sha256:b16cef8cbcb20935c0f052e37fc3d38dc92bfec0bcfb894c328547f81e932d67 0.0s
=> => sha256:b16cef8cbcb20935c0f052e37fc3d38dc92bfec0bcfb894c328547f81e932d67 1.85kB / 1.85kB 0.0s
=> => sha256:d1fbb74d3e14bce3a324a08c0e89ba99285c28a6886c295871d86f853e1821fc 529B / 529B 0.0s
=> => sha256:a6916e41aa871b09260f8949fe3c34570719f1c92ffe87d515b7eb702ebaebb1 1.46kB / 1.46kB 0.0s
=> => sha256:1b13d4e1a46e5e969702ec92b7c787c1b6891bff7c21ad378ff6dbc9e751d5d4 49.56MB / 49.56MB 2.0s
=> => extracting sha256:1b13d4e1a46e5e969702ec92b7c787c1b6891bff7c21ad378ff6dbc9e751d5d4 1.0s
=> [internal] load build context 0.1s
=> => transferring context: 6.78kB 0.0s
=> [2/7] COPY ./.python-version /.python-version 0.1s
=> [3/7] COPY ./ci/lint/container-entrypoint.sh /entrypoint.sh 0.1s
=> [4/7] COPY ./ci/lint/04_install.sh /install.sh 0.1s
=> [5/7] COPY ./test/lint/test_runner /test/lint/test_runner 0.1s
=> [6/7] RUN /install.sh && echo 'alias lint="./ci/lint/06_script.sh"' >> ~/.bashrc && chmod 755 /entrypoint.sh && 155.6s
=> [7/7] WORKDIR /bitcoin 0.1s
=> exporting to image 7.2s
=> => exporting layers 7.2s
=> => writing image sha256:ab4f85fd71350e3f776adb68c125f862111e3c19ce6e9a3cacdf05202a2c4fac 0.0s
=> => naming to docker.io/library/bitcoin-linter 0.0s
+ '[' -n 1 ']'
++ git merge-base HEAD master
+ COMMIT_RANGE=c2d04f1319a6af6140d17339c4814e0cfc605dd2..HEAD
+ export COMMIT_RANGE
+ RUST_BACKTRACE=1
+ /lint_test_runner/test_runner
src/crypto/ctaes in HEAD currently refers to tree 1b6c31139a71f80245c09597c343936a8e41d021
src/crypto/ctaes in HEAD was last updated in commit 8501bedd7508ac514385806e191aec21ee978891 (tree 1b6c31139a71f80245c09597c343936a8e41d021)
GOOD
src/secp256k1 in HEAD currently refers to tree 4f5d0a37a5ce94a773267b04af331b5f680b0433
src/secp256k1 in HEAD was last updated in commit 29fde0223abc706925188014209eba75390a9df8 (tree 4f5d0a37a5ce94a773267b04af331b5f680b0433)
GOOD
src/minisketch in HEAD currently refers to tree a749309e1b4edf48091edb57da6de2e8a16498a5
src/minisketch in HEAD was last updated in commit e9f1d8c27261070d209a28570ad36fe91531cdd2 (tree a749309e1b4edf48091edb57da6de2e8a16498a5)
GOOD
src/leveldb in HEAD currently refers to tree bd49d3c60051c1a8d8f030fa4ba7a29237fe7479
src/leveldb in HEAD was last updated in commit 1a463c70a368fb20316e03efac273438cf47baa3 (tree bd49d3c60051c1a8d8f030fa4ba7a29237fe7479)
GOOD
src/crc32c in HEAD currently refers to tree 5a1b5f7188bd2181e2a71d431fff282d50058e46
src/crc32c in HEAD was last updated in commit 08269e54a9a74e06c9fb72720a216d8c4d4532a2 (tree 5a1b5f7188bd2181e2a71d431fff282d50058e46)
GOOD
Args used : 209
Args documented : 220
Args undocumented: 0
set()
Args unknown : 11
{'-zmqpubhashblockhwm', '-zmqpubsequence', '-zmqpubrawtxhwm', '-zmqpubhashtx', '-zmqpubrawblock', '-zmqpubrawblockhwm', '-zmqpubrawtx', '-zmqpubsequencehwm', '-zmqpubhashtxhwm', '-includeconf', '-zmqpubhashblock'}
src/test/fuzz/package_eval.cpp:214: non-existant ==> non-existent
src/test/span_tests.cpp:56: memeber ==> member
^ Warning: codespell identified likely spelling errors. Any false positives? Add them to the list of ignored words in test/lint/spelling.ignore-words.txt
Success: no issues found in 280 source files
+ '[' '' = bitcoin/bitcoin ']'
|
ACK fa2b95c |
Seems confusing to have a test runner that calls another runner (
all-lint.py), which calls a subset of the lint tests.Fix that by just calling this subset of lint tests in the test runner directly, and remove the now unused
all-lint.py.To run all lint checks locally, refer to the documentation: https://github.com/bitcoin/bitcoin/blob/master/test/lint/README.md#running-locally