[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: Fixed in distutils2 in 95172b1c5498. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset a78629c62ee8 by Éric Araujo in branch '3.2': Make bdist_* commands respect --skip-build passed to bdist (#10946) http://hg.python.org/cpython/rev/a78629c62ee8 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 326a7e44bb66 by Éric Araujo in branch '3.2': Make bdist_* commands respect --skip-build passed to bdist (#10946) http://hg.python.org/cpython/rev/326a7e44bb66 New changeset 2f69b4f3df2e by Éric Araujo in branch 'default': Merge fix for #10946 from 3.2 http://hg.python.org/cpython/rev/2f69b4f3df2e New changeset afb12c6b79ba by Éric Araujo in branch 'default': Make bdist_* commands respect --skip-build passed to bdist (#10946). http://hg.python.org/cpython/rev/afb12c6b79ba -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 4ff92eb1a915 by Éric Araujo in branch '2.7': Make bdist_* commands respect --skip-build passed to bdist (#10946) http://hg.python.org/cpython/rev/4ff92eb1a915 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: I simplified my patch and pushed it. I had to discover again that I needed to inject customized command objects into dist.command_obj, like you found out a few months ago when we had a private email discussion :) Using set_undefined_options in install_* is definitely not safe, because it fails if parent [command] has not set skip_build. We can be sure (by looking at the code) that bdist always sets skip_build to something (False by default), so it’s not unsafe. Also skip_build has to be set to None in install_* (set_... needs that to work) which obviously breaks it. Yes, skip_build on the subcommands needed to change from None to False, but I don’t see how it is a breakage; it’s just an harmless change needed for this bug fix, so I did it. :) Thanks to everyone involved in this bug. -- resolution: - fixed stage: commit review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: The fix was actually very simple. I have committed it to my 3.2 repo and will push later. -- stage: test needed - commit review Added file: http://bugs.python.org/file23061/fix-bdist-skip-build.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Changes by Éric Araujo mer...@netwok.org: -- hgrepos: +27 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Changes by Éric Araujo mer...@netwok.org: Added file: http://bugs.python.org/file22335/a099e7001aa8.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: I’ll edit the patch to use set_undefined_options. -- versions: +Python 3.3 -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Changes by Senthil Kumaran sent...@uthcode.com: -- nosy: +orsenthil ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: Could you please at least describe the test that you mentioned (link doesn't work). I still have a local copy \o/. Yannick’s patch looks like this: def test_skip_build(self): pkg_pth, dist = self.create_dist() # With the skip_build option, command.build is not called. cmd = bdist(dist) cmd.skip_build = True cmd.ensure_finalized() cmd.run() self.assertFalse(dist.have_run['build']) # Without skip_build option, command.build is called. cmd = bdist(dist) cmd.skip_build = False cmd.ensure_finalized() cmd.run() self.assertTrue(dist.have_run['build']) I added line that passes skip_build from bdist.py to its subcommands and it worked for me (at least for simple cases) What about non-simple cases? They need to work too. - base.py is not called. (Assuming you meant “build is not called”) Using set_undefined_options in install_* is definitely not safe, because it fails if parent process has not set skip_build. Really? Also, what is “parent process”? Do you mean that it fails if the command used as source in set_undefined_options does not define the skip_build option in its user_options? I’m not sure it’d be good to make the install_* skip_build option depend on (== set_undefined_options from) bdist’s skip_build. I’ve written a bit of code to make testing interaction between commands easier (for example, to test that “setup.py build bdist --skip-build install” runs the second install command without skip_build set to True), I should put it in the main repo so that it can be used for this bug. Getting good test coverage before we change code is absolute requisite for those dark areas. Removing the easy keyword :) Anyway test_skip_build() is still broken and needs a fix. Okay, so maybe fix that first. -- keywords: -easy stage: needs patch - test needed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Wojciech Wojtyniak radi...@gmail.com added the comment: Could you please at least describe the test that you mentioned (link doesn't work). I added line that passes skip_build from bdist.py to its subcommands and it worked for me (at least for simple cases) - base.py is not called. If bdist wouldn't call any install_* in other way then via bdist_*, then we could use set_undefined_options in the last ones, but I'm not sure if it's safe. (If it is, I can provide appropriate patch.) Using set_undefined_options in install_* is definitely not safe, because it fails if parent process has not set skip_build. Also skip_build has to be set to None in install_* (set_... needs that to work) which obviously breaks it. Actually bdist_* sets skip_build like in my patch. Patch attached. Anyway test_skip_build() is still broken and needs a fix. -- keywords: +patch nosy: +radious Added file: http://bugs.python.org/file21689/skip_build.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
New submission from Éric Araujo mer...@netwok.org: Yannick has found that bdist_* commands don’t get the --skip-build option from bdist. This should be solved easily thanks to set_undefined_options. Adding people from #414775 (r25075) to nosy. -- assignee: eric.araujo components: Distutils, Distutils2 keywords: easy messages: 126530 nosy: eric.araujo, kern, loewis, ygingras priority: normal severity: normal stage: needs patch status: open title: bdist doesn’t pass --skip-build on to subcommands type: behavior versions: 3rd party, Python 2.7, Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Changes by Éric Araujo mer...@netwok.org: -- nosy: +tarek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Éric Araujo mer...@netwok.org added the comment: I added the required calls to pass skip-build from bdist to bdist_* but that isn’t enough to make the test from https://bitbucket.org/ygingras/distutils2/changeset/71f5c39c9100 pass. build gets somehow called, even though install, install_lib, bdist and bdist_dumb have skip_build set to 0. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com