lint: Add linter for circular dependencies#13695
Merged
Merged
Conversation
Contributor
|
Neato! :) Tested ACK on bash 3.2.57(1)-release (macOS). |
Contributor
Author
|
Fixed inconsistent trailing space between cases. |
Contributor
There was a problem hiding this comment.
Description should be updated :-)
Contributor
Author
There was a problem hiding this comment.
Updated description. Thanks!
Contributor
There was a problem hiding this comment.
Nit: Please sort these entries to make it easy to find a specific circular dependency in the list.
Contributor
Author
There was a problem hiding this comment.
These are sorted consistent with the output of contrib/devtools/circular-dependencies.py, which is deterministic. #13228 (comment)
Contributor
|
Very very nice! This will help us get rid of circular dependencies permanently! Thanks for doing this. ACK 54f16f23e886f6c37189aa53c86cdb0cefa809ea modulo nits |
Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh
Contributor
|
ACK 5c613aa |
Member
|
utACK 5c613aa |
laanwj
added a commit
that referenced
this pull request
Jul 20, 2018
5c613aa lint: Add linter for circular dependencies (Ben Woosley) Pull request description: Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh Example output: ``` $ test/lint/lint-circular-dependencies.sh A new circular dependency in the form of "qt/paymentserver -> qt/walletmodel -> qt/paymentserver" appears to have been introduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh Good job! The circular dependency "Fake" is no longer present. Please remove it from EXPECTED_CIRCULAR_DEPENDENCIES in test/lint/lint-circular-dependencies.sh to make sure this circular dependency is not accidentally reintroduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh $ echo $? 0 ``` Tree-SHA512: 4519434de29f6d50859daed1480e531c01c1cdbc3f0a5f093251daf62ae2b5b9073fb274b86f541a985e06837aa1165b76558c5f35fb51a759d72e83f1b61e44
deadalnix
pushed a commit
to Bitcoin-ABC/bitcoin-abc
that referenced
this pull request
May 5, 2020
Summary: Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh --- This is a backport of Core [[bitcoin/bitcoin#13695 | PR13695]] Test Plan: run ./test/lint/lint-circular-dependencies.py see output that points existing unexpected dependencies, expected dependencies that aren't present and unexpected dependencies that are. Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D5962
ftrader
pushed a commit
to bitcoin-cash-node/bitcoin-cash-node
that referenced
this pull request
Aug 17, 2020
Summary: Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh --- This is a backport of Core [[bitcoin/bitcoin#13695 | PR13695]] Test Plan: run ./test/lint/lint-circular-dependencies.py see output that points existing unexpected dependencies, expected dependencies that aren't present and unexpected dependencies that are. Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Differential Revision: https://reviews.bitcoinabc.org/D5962
PastaPastaPasta
pushed a commit
to PastaPastaPasta/dash
that referenced
this pull request
Feb 4, 2021
5c613aa lint: Add linter for circular dependencies (Ben Woosley) Pull request description: Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh Example output: ``` $ test/lint/lint-circular-dependencies.sh A new circular dependency in the form of "qt/paymentserver -> qt/walletmodel -> qt/paymentserver" appears to have been introduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh Good job! The circular dependency "Fake" is no longer present. Please remove it from EXPECTED_CIRCULAR_DEPENDENCIES in test/lint/lint-circular-dependencies.sh to make sure this circular dependency is not accidentally reintroduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh $ echo $? 0 ``` Tree-SHA512: 4519434de29f6d50859daed1480e531c01c1cdbc3f0a5f093251daf62ae2b5b9073fb274b86f541a985e06837aa1165b76558c5f35fb51a759d72e83f1b61e44
gades
pushed a commit
to cosanta/cosanta-core
that referenced
this pull request
Jul 1, 2021
5c613aa lint: Add linter for circular dependencies (Ben Woosley) Pull request description: Protects against added circular depencies, makes it explicit in the code when circular dependencies have been removed. Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh Example output: ``` $ test/lint/lint-circular-dependencies.sh A new circular dependency in the form of "qt/paymentserver -> qt/walletmodel -> qt/paymentserver" appears to have been introduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh Good job! The circular dependency "Fake" is no longer present. Please remove it from EXPECTED_CIRCULAR_DEPENDENCIES in test/lint/lint-circular-dependencies.sh to make sure this circular dependency is not accidentally reintroduced. $ echo $? 1 $ test/lint/lint-circular-dependencies.sh $ echo $? 0 ``` Tree-SHA512: 4519434de29f6d50859daed1480e531c01c1cdbc3f0a5f093251daf62ae2b5b9073fb274b86f541a985e06837aa1165b76558c5f35fb51a759d72e83f1b61e44
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Protects against added circular depencies, makes it explicit in the
code when circular dependencies have been removed.
Modeled after EXPECTED_BOOST_INCLUDES in lint-includes.sh
Example output: