This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author jaraco
Recipients FFY00, barry, jaraco
Date 2021-01-10.17:47:48
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1610300868.57.0.56373394338.issue42129@roundup.psfhosted.org>
In-reply-to
Content
In [this commit](https://github.com/python/importlib_resources/commit/bd20d893f11f387d285c666bc99fd2d4a7c33ef8), I've reconciled and merged the changes from importlib_resources 3.2-5.0, mainly the namespace package support (https://importlib-resources.readthedocs.io/en/latest/history.html#v5-0-0).

Applying these changes to cpython and running the tests, there appear to be two emergent failure modes:

```
cpython master $ http --follow https://github.com/python/importlib_resources/archive/cpython.zip | bsdtar --strip-components 1 -x
$ ./python.exe Tools/scripts/run_tests.py test.test_importlib 2>&1 | gist -Pc
https://gist.github.com/dde7d5a951d92726380dced21503f843
```

In my estimation, the first two failures are due to the change in the abc.ResourceReader for contents to raise FileNotFoundError.

And the latter failures are seemingly due to the built-in NamespaceLoader not having a resource reader. I suspect the fix here is to add a .get_resource_reader() method to _NamespaceLoader to return a NamespaceReader. (hint: when updating _bootstrap_external.py, you'll need to run `make regen-importlib` or `make regen-all` and recompile).

Filipe, would you be interested in exploring these issues and propose some fixes and prepare the PR that applies the changes to CPython?
History
Date User Action Args
2021-01-10 17:47:48jaracosetrecipients: + jaraco, barry, FFY00
2021-01-10 17:47:48jaracosetmessageid: <1610300868.57.0.56373394338.issue42129@roundup.psfhosted.org>
2021-01-10 17:47:48jaracolinkissue42129 messages
2021-01-10 17:47:48jaracocreate