gauge-sh / tach

A Python tool to enforce dependencies, using modular architecture 🌎 Open source 🐍 Installable via pip πŸ”§ Able to be adopted incrementally - ⚑ Implemented with no runtime impact ♾️ Interoperable with your existing systems πŸ¦€ Written in rust
https://gauge.sh
MIT License
1.01k stars 35 forks source link

Improve error message when tach report runs on an exact source root #275

Closed emdoyle closed 3 weeks ago

emdoyle commented 3 weeks ago

Fixes #274

image

Given that tach report provides a report on usages and dependencies across the boundary of the module, passing the path to an exact source root is an error. There is no content which is considered 'external' to the source root, so there can be no usages or dependencies.

As an example, if I have a source root at ./python, that means that my Python imports are relative to this path. That is, importing from ./python/a.py would be done as import a. Importing the source root itself is not possible.