Message310319
Thanks Larry - I've reduced the priority accordingly.
While the NEWS entry sounds a bit complicated, the actual fix is nicely self-contained: it's all within Modules/main.c, and relates to how that manipulates sys.argv[0] during startup.
Historically, the code would put a potentially incorrect entry into sys.path[0], then amend it later (and that amendment step could sometimes do the wrong thing), but after this patch, it stores the candidate entry in a local C variable and adds it to the path only after it knows it's correct to do so.
The backport also comes with test cases to ensure everything's working as we expect, and this is the code that 3.6 has been using since its release. |
|
Date |
User |
Action |
Args |
2018-01-20 02:47:43 | ncoghlan | set | recipients:
+ ncoghlan, brett.cannon, larry, christian.heimes, nedbat, petr.viktorin, eryksun, steve.dower |
2018-01-20 02:47:43 | ncoghlan | set | messageid: <1516416463.36.0.467229070634.issue32551@psf.upfronthosting.co.za> |
2018-01-20 02:47:43 | ncoghlan | link | issue32551 messages |
2018-01-20 02:47:42 | ncoghlan | create | |
|