-
-
Notifications
You must be signed in to change notification settings - Fork 276
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
Defining a module foo
results in foo.foo
being available
#1399
Comments
foo
results in foo.foo
being available (pyo3)foo
results in foo.foo
being available
It is by design, see also #1365 |
What is the reasoning behind this design decision? (Sidenote: If the For my project I would prefer the |
See #558, it allows package type stubs automatically.
You can use mixed layout to do this, see https://www.maturin.rs/project_layout.html#import-rust-as-a-submodule-of-your-project |
I don't see anything about putting the
(Putting |
That would miss the |
Ah yes of course, you're correct that this wouldn't work with I just opened python/typing#1333 about introducing some way to mark |
Workaround-For: PyO3/maturin#1399 Workaround-For: python/typing#1333
Run
maturin new -b pyo3 foo
, followed bymaturin dev
in a venv.I would expect
foo.foo
to be undefined. The same can be observed when using rust-cpython.Versions:
The text was updated successfully, but these errors were encountered: