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

Support imports of additional modules #16

Open
Lonami opened this issue Jan 10, 2021 · 0 comments
Open

Support imports of additional modules #16

Lonami opened this issue Jan 10, 2021 · 0 comments

Comments

@Lonami
Copy link
Owner

Lonami commented Jan 10, 2021

Split off https://github.com/Lonami/pyndustric/pull/12/files#diff-852dce7acd90bf3bfbde1cec63522f7204b9c209cc52b3e40d23bb6f3202ef7fR54-R55.

It would be necessary to inspect import statements and figure out what's used from them.

This issue won't be easy to tackle, because even if the user does from foo import bar, bar might be relying on the baz or even be compiled conditionally depending on qux. From an implementation-perspective:

  1. Assume the imported function is self-contained.
  2. Actually validate that the function is self-contained an error at compile time, to prevent running broken mlog.
  3. Smarter imports which will be able to handle some of the cases where 2. errors out (probably not possible to handle them all without extreme clutter).
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