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
A compliant PEP 451 loader can avoid a lot of the tricky APIs just through implementing find_spect -- in this case is_package is replaced by submodule_search_locations being truthy
I'll see if I can't take a stab at this, it looks like this is a reopen of #487
$ pytest t.py============================= test session starts ==============================platform linux -- Python 3.6.7, pytest-5.0.0, py-1.8.0, pluggy-0.12.0rootdir: /tmp/xcollected 0 items / 1 errors ==================================== ERRORS ====================================____________________________ ERROR collecting t.py _____________________________t.py:3: in <module> app = flask.Flask(__name__)venv/lib/python3.6/site-packages/flask/app.py:381: in __init__ instance_path = self.auto_find_instance_path()venv/lib/python3.6/site-packages/flask/app.py:678: in auto_find_instance_path prefix, package_path = find_package(self.import_name)venv/lib/python3.6/site-packages/flask/helpers.py:826: in find_package loader, root_mod_name):venv/lib/python3.6/site-packages/flask/helpers.py:789: in _matching_loader_thinks_module_is_package loader.__class__.__name__)E AttributeError: AssertionRewritingHook.is_package() method is missing but is required by Flask of PEP 302 import hooks. If you do not use import hooks and you encounter this error please file a bug against Flask.!!!!!!!!!!!!!!!!!!! Interrupted: 1 errors during collection !!!!!!!!!!!!!!!!!!!!=========================== 1 error in 0.31 seconds ============================
For more information: pytest-dev/pytest#5532
https://www.python.org/dev/peps/pep-0451/#api-changes
A compliant PEP 451 loader can avoid a lot of the tricky APIs just through implementing
find_spect
-- in this caseis_package
is replaced bysubmodule_search_locations
being truthyI'll see if I can't take a stab at this, it looks like this is a reopen of #487
Here's a minimal example:
The text was updated successfully, but these errors were encountered: