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 vinay.sajip
Recipients alexis, ceder, eric.araujo, fdrake, higery, mhammond, tarek, tim.golden, vinay.sajip
Date 2011-10-24.12:21:49
SpamBayes Score 1.7707343e-05
Marked as misclassified No
Message-id <1319458911.23.0.92907408001.issue12394@psf.upfronthosting.co.za>
In-reply-to
Content
FYI: In pythonv, the build_scripts functionality provides identical support for dotted callables to what Éric proposed, while preserving existing functionality for ordinary script files. Thus:

scripts = demo1
  demo2 = amodule.main
  demo3 = apackage.asubpackage.main gui

copies demo1 (adjusting its shebang) and creates demo2 and demo3 from the dotted callables (using the appropriate shebang).

While working on this, I came up against a problem with build_scripts in virtual environments: if I install a project into virtual env 1, then scripts are built with shebangs pointing to that env. If I then install the same project into virtual env 2, then the scripts are not re-created, so they would be installed into virtual env 2 with shebangs referencing virtual env 1. One solution is to set the force flag for virtual environments, but then if you later install into the system Python, then files with wrong shebangs could be installed there. I think the force flag should default to True for build_scripts; the extra script build time would be negligible except in pathological cases. Do you agree?
History
Date User Action Args
2011-10-24 12:21:51vinay.sajipsetrecipients: + vinay.sajip, mhammond, fdrake, ceder, tim.golden, tarek, eric.araujo, alexis, higery
2011-10-24 12:21:51vinay.sajipsetmessageid: <1319458911.23.0.92907408001.issue12394@psf.upfronthosting.co.za>
2011-10-24 12:21:50vinay.sajiplinkissue12394 messages
2011-10-24 12:21:50vinay.sajipcreate