Jason R. Coombs
Jason R. Coombs
> Does it mean that `distutils` can be imported _even in Python 3.12_ if `setuptools` is installed ? Yes. That's correct. The only exception is that if `SETUPTOOLS_USE_DISTUTILS=stdlib` is set,...
In https://github.com/pypa/distutils/pull/295, I've started work on refactoring the compilers functionality in distutils such that it can be exposed separately and publicaly in a new namespace. Along with the other recent...
An even better alternative would be to use [importlib_metadata](https://pypi.org/project/importlib_metadata), which has an API. ``` >>> import importlib_metadata >>> importlib_metadata.metadata('xonsh').get_all('Provides-Extra') ['linux', 'mac', 'proctitle', 'ptk', 'pygments', 'win'] >>> importlib_metadata.metadata('xonsh').get_all('Requires-Dist') ["distro; extra ==...
And use [packaging](https://pypi.org/project/packaging) to parse them: ``` >>> req = next(map(packaging.requirements.Requirement, importlib_metadata('xonsh').get_all('Requires-Dist'))) >>> req.name 'distro' >>> req.specifier >>> req.extras set() >>> req.marker ```
As discussed in #495, this isn't the right approach to take. `importlib_metadata` is compatible with the fixed version and will pick it up by default. It's up to downstream integrators...
I stumbled onto this issue while working on https://github.com/python/importlib_resources/issues/287. In https://github.com/python/importlib_resources/commit/496acc1a0d8018c830b30a3a28826c9b101975fa, I factored out the zip files that the tests use to dynamically generate the zip fixtures so that I...
This problem is another manifestation of https://github.com/pypa/packaging-problems/issues/342. Essentially, it's not possible for build backends (or their plugins) to have dependencies that use said build backend. I've proposed several solutions, but...
There are many hacks that system integrators have used to work around the cyclic dependency issues, namely: - avoiding use of setuptools_scm by hand-coding the version with SETUPTOOLS_SCM_PRETEND_VERSION (or similar)...
I think the short answer is no, mainly because Setuptools (and by extension every backend that has dependencies that lead to itself) would need to re-write the user's sources to...
> As build backends can report additional dependencies the idea is more around being able to skip some if the metadata is provided by the sdist instead of rewriting the...