[issue12302] packaging test command needs access to .dist-info
Changes by Éric Araujo mer...@netwok.org: -- resolution: - out of date stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12302 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12302] packaging test command needs access to .dist-info
Éric Araujo mer...@netwok.org added the comment: For #8668 (develop command), higery has written code that reuses install_distinfo to create the dist-info dir in the build dir. It requires #12344, which I will commit when Thomas has time to finish his patch. We also need to make install_distinfo more flexible: For example, on #12279 we discussed about the RECORD file, which should be empty when created by the test command (nothing is installed), and we mentioned RESOURCES, which should probably be created, with relative paths. (The resources API is intended to work with zero config in a source checkout or unpacked tarball, even though it currently doesn’t, but given that test runs in the build dir, we’re not in the source dir anymore, so RESOURCES should probably be written.) -- dependencies: +Add **kwargs to get_reinitialized_command nosy: +higery ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12302 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12302] packaging test command needs access to .dist-info
Éric Araujo mer...@netwok.org added the comment: while running the test command (pysetup run test)? Yes, that’s the correct invocation. The use case: [...] I agree with the need. I’ve added a dep on the bug requesting the addition of a build_distinfo command; once it is done, this bug will be solved, since test runs build and places the build lib in sys.path (which also enables running tests on code converted by 2to3 at build time). The function that finds the configuration uses sysconfig paths (sysconfig.get_paths) which rely on the packaging database (PEP 376 API now in packaging.database). sysconfig does rely on packaging. To find the default config, or resource in packaging terms, I'm using the packaging.database.get_file_path, which requires the distribution metadata (dist-info) be available within the Python path This however is correct. I'd like to know where this RESOURCES file came from? I don't recall, nor see mention of it in PEP 376. This is the implementation of the discussion originally started in https://bitbucket.org/tarek/distutils2/src/6c3d67ed3adb/docs/design/wiki.rst I think it was originally intended to be a new PEP, but during distutils2 sprints it was directly coded. Resources replace data_files. I would also have expected to find something in packaging.command.install_distinfo command related to this file. It’s subtle; grep for RESOURCES and you’ll find it. The list of files is built by install_data and written by install_distinfo. If you want to learn more about this code, go to a distutils2 repo and look at the log. -- assignee: tarek - eric.araujo dependencies: +Add build_distinfo command to packaging title: test command is not loading the distribution metadata - packaging test command needs access to .dist-info ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12302 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12302] packaging test command needs access to .dist-info
Éric Araujo mer...@netwok.org added the comment: Typo: sysconfig does *not* rely on packaging. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12302 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com