Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore modules in library search path #169

Open
nmichlo opened this issue Nov 30, 2022 · 0 comments
Open

Ignore modules in library search path #169

nmichlo opened this issue Nov 30, 2022 · 0 comments

Comments

@nmichlo
Copy link

nmichlo commented Nov 30, 2022

Sometimes it makes sense to group helper utilities together in in the library search path.

However, we don't always want these files to be loaded if for example the model itself is not used.

  • The problem is that modelkit traverses and loads all python modules in the search path. It would be useful to be able to skip over specific files.

This could maybe be done with a common naming convention, for example prefixing files that should be ignored with some standard prefix, eg. library._my_module would be ignored and skipped over (this follows private convention, with the underscore indicating a module that should not be exposed publicly), while library.my_module would be traversed and loaded.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant