Open sbrugman opened 6 months ago
Interesting idea! So are you thinking this would be a new contract type?
One option for this would be to implement it as a custom contract to begin with. It could even be published as its own PyPI package and have a different maintainer, if someone is interested.
Prematurely generalization by moving functions to different modules (e.g. common, utils) can lead to a convoluted codebases. This can lead to global chaos, especially in mono-repos.
It would be interesting to be able to require a minimum number of imports between certain modules, for instance, utility functions at the top level of the module need to be imported by at least two submodules. (Two+ links in the import graph)
(If you think in terms of number of links, then
forbidden
is just the special case wheremax=0
)