Repository navigation
MAINT: add test to prevent new public-looking modules being added - #14454
Conversation
|
Hmm, we start with a failure that I can't reproduce locally: shows up for an install, but not an in-place build. adding it to the list |
Can you elaborate on what you mean by this? |
The comment explicitly said not to add The root cause is that in our main |
Also finish the TODO about figuring out which np.lib.<submodule>'s are public. This is a giant mess ...
Also address other review comments.
fe73481 to
069e115
Compare
Also remove `numpy.ma.version.py`, it was not importable and served no purpose.
069e115 to
9530d43
Compare
|
Thanks @rgommers. I guess the next step is to identify candidates for namespace deprecation. |
Before that, lower-hanging fruit may be to remove |
| "random.philox", | ||
| "random.sfc64", | ||
| "testing.decorators", | ||
| "testing.noseclasses", |
There was a problem hiding this comment.
This broke the wheel builds, I suspect because nose is not present in those builds. Nose doesn't support recent Python3 out of the box.
There was a problem hiding this comment.
nose is optional, and if not present an import error will be raised if a attempt to import it is made.
There was a problem hiding this comment.
thanks. okay that's easy to fix, PR to follow
Removes these files that were deprecated since 1.15.0: - numpy/testing/decorators.py - numpy/testing/noseclasses.py - numpy/testing/nosetester.py This also resolves a failure in the recently introduced tests in `test_public_api.py` (see numpygh-14454). Closes numpygh-14566
There is more work to do (added a FIXME), but that's for another time. Preventing to add new submodules is a good start. Also added some documentation, and split things into public and private submodules with comments.
The change to
numpy.lib.mixins.__all__shows that people have been working around ourimport *mess sometimes. Not adding some public object to an__all__dict is incorrect of course - need a more structural fix by getting rid of*imports.