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
Thanks for the awesome tool. I'm doing some research on a big Python project and I try to improve the number of top-level imports/imported_by. I don't care about imports inside function definition since they do not raise problems for import cycles… Is there a way to only report the top-level imports and exclude imports inside function definition?
Thanks!
The text was updated successfully, but these errors were encountered:
Hi @ThibaudDauce and thank you for your interest in pydeps.
Pydeps uses (a patched version of) the standard library moduluefinder module and unfortunaetly there is no functionality there that knows whether an import is in the global namespace.
If you want to look into the possibility of making this (i.e. making the modulefinder code context aware) work, the code that needs to change is in pydeps/mf27.py in the ModuleFinder.scan_code(..) method. (I'm always happy to merge PRs ;-) )
Hi,
Thanks for the awesome tool. I'm doing some research on a big Python project and I try to improve the number of top-level imports/imported_by. I don't care about imports inside function definition since they do not raise problems for import cycles… Is there a way to only report the top-level imports and exclude imports inside function definition?
Thanks!
The text was updated successfully, but these errors were encountered: