Issue 36245: PCBuild/build.bat errors, probably from space characters in paths (original) (raw)

Created on 2019-03-08 21:28 by Jess, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 12241 merged Jess,2019-03-08 21:47
PR 12484 merged miss-islington,2019-03-21 16:03
PR 12591 merged steve.dower,2019-03-27 15:43
PR 12592 merged steve.dower,2019-03-27 15:46
PR 12595 merged miss-islington,2019-03-27 23:28
Messages (15)
msg337530 - (view) Author: Jess (Jess) * Date: 2019-03-08 21:28
Have a fix for this that I'll send off shortly. What I see with the current head (my username was replaced with "Foo Bar" in this example: > Using "C:\Users\Foo Bar\cpython\PCbuild\\..\externals\pythonx86\tools\python.exe" (found in externals directory) > Bar\cpython\PCbuild\\..\externals\pythonx86\tools\python.exe""=="" was unexpected at this time. My theory, window's turning: > C:\Users\Foo Bar into > "C:\Users\Foo Bar" and this is colliding with our use of "%PYTHON%", creating double quotes, or: > ""C:\Users\Foo Bar"" which, of course: > if ""C:\Users\Foo Bar""=="" does not make sense as a statement.
msg337531 - (view) Author: Jess (Jess) * Date: 2019-03-08 21:29
Note: the error is actually in get_externals.bat, which is called by build.bat.
msg337544 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-08 23:11
Since the checks are all against empty strings, perhaps we can use "IF NOT DEFINED PYTHON" instead? That should work as well, I think, and it'll save us from problems in the future if someone puts "]" in their username :)
msg337959 - (view) Author: Jess (Jess) * Date: 2019-03-15 01:01
Alas, "IF NOT DEFINED PYTHON" isn't working - as it's even more possible to get into a state where PYTHON="" than it is for a bracket to be in the python name. Thus, the system would think it declared where we would have created it into an actual path otherwise.
msg337960 - (view) Author: Jess (Jess) * Date: 2019-03-15 01:14
Looks like the brackets are fine even in the bracket case Steve mentioned. @echo off if NOT DEFINED ABCDEF ( echo "all good" ) if NOT DEFINED ABCDE ( echo "all good2" ) set ABCDE= if NOT DEFINED ABCDE ( echo "sadness" ) if [%ABCDE%]==[] ( echo "all good3" ) set ABCDE=] if [%ABCDE%] NEQ [] ( echo "all good4" ) set ABCDE="]" if [%ABCDE%] NEQ [] ( echo "all good5" ) >demo.bat "all good" "sadness" "all good3" "all good4" "all good5"
msg337962 - (view) Author: Jess (Jess) * Date: 2019-03-15 01:25
Nevermind, the hold over issue was from another bit. Updated the change request.
msg338142 - (view) Author: Jess (Jess) * Date: 2019-03-17 21:40
How long should I be waiting on review?
msg338215 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-18 12:42
For this one you're probably waiting on me to get time. I try to find an hour or two each week, depending on what releases are going on, but it can be a little unpredictable. Zachary could also review and merge if he gets time first. I don't think anyone else is likely to look at this.
msg338552 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-21 16:03
New changeset 7ee88bf3e59493137a775368165c5c5fe1ed7f46 by Steve Dower (Jess) in branch 'master': bpo-36245: Avoid problems when building in a directory containing spaces. (GH-12241) https://github.com/python/cpython/commit/7ee88bf3e59493137a775368165c5c5fe1ed7f46
msg338553 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-21 16:05
Fixed for 3.7 and master. If it needs to go into 2.7 then someone will need to backport it manually.
msg338554 - (view) Author: miss-islington (miss-islington) Date: 2019-03-21 16:25
New changeset b058a97c90c3144cc602b719483572916b3918bb by Miss Islington (bot) in branch '3.7': bpo-36245: Avoid problems when building in a directory containing spaces. (GH-12241) https://github.com/python/cpython/commit/b058a97c90c3144cc602b719483572916b3918bb
msg338971 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-27 15:48
I did the 2.7 backport, and also fixed two more instances in that file. Pretty sure my automerges won't work without a core dev review, so if someone wants to hit Approve and/or Merge for me, feel free.
msg338995 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-27 23:28
New changeset bb89aa24cf71f9874d1d26f3a2440fefa0b6bbcc by Steve Dower in branch '2.7': bpo-36245: Avoid problems when building in a directory containing spaces. (GH-12241) https://github.com/python/cpython/commit/bb89aa24cf71f9874d1d26f3a2440fefa0b6bbcc
msg338996 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-03-27 23:28
New changeset b95a79c928fc4a6135d91c0c553cb2a63cf15140 by Steve Dower in branch 'master': bpo-36245: Fix more empty environment variable checks (GH-12592) https://github.com/python/cpython/commit/b95a79c928fc4a6135d91c0c553cb2a63cf15140
msg338999 - (view) Author: miss-islington (miss-islington) Date: 2019-03-28 00:01
New changeset 1ff04dcadfb57a8a8f61a6ea93292e8ae96dca4a by Miss Islington (bot) in branch '3.7': bpo-36245: Fix more empty environment variable checks (GH-12592) https://github.com/python/cpython/commit/1ff04dcadfb57a8a8f61a6ea93292e8ae96dca4a
History
Date User Action Args
2022-04-11 14:59:12 admin set github: 80426
2019-03-28 00:01:33 miss-islington set messages: +
2019-03-27 23:29:29 steve.dower set status: open -> closedresolution: fixedstage: patch review -> resolved
2019-03-27 23:28:55 miss-islington set pull_requests: + <pull%5Frequest12538>
2019-03-27 23:28:43 steve.dower set messages: +
2019-03-27 23:28:36 steve.dower set messages: +
2019-03-27 15:48:12 steve.dower set messages: +
2019-03-27 15:46:12 steve.dower set pull_requests: + <pull%5Frequest12535>
2019-03-27 15:43:57 steve.dower set stage: backport needed -> patch reviewpull_requests: + <pull%5Frequest12534>
2019-03-21 16:25:24 miss-islington set nosy: + miss-islingtonmessages: +
2019-03-21 16:05:22 steve.dower set stage: patch review -> backport neededmessages: + versions: - Python 3.4, Python 3.5, Python 3.6
2019-03-21 16:03:21 miss-islington set pull_requests: + <pull%5Frequest12437>
2019-03-21 16:03:09 steve.dower set messages: +
2019-03-18 12:42:51 steve.dower set assignee: steve.dowermessages: +
2019-03-17 21:40:13 Jess set messages: +
2019-03-15 01:25:42 Jess set messages: + versions: + Python 2.7, Python 3.4, Python 3.5, Python 3.6
2019-03-15 01:14:39 Jess set messages: +
2019-03-15 01:01:57 Jess set messages: +
2019-03-08 23:11:59 steve.dower set components: + Buildversions: + Python 3.7, Python 3.8
2019-03-08 23:11:43 steve.dower set messages: +
2019-03-08 21:47:40 Jess set keywords: + patchstage: patch reviewpull_requests: + <pull%5Frequest12229>
2019-03-08 21:29:32 Jess set messages: +
2019-03-08 21:28:39 Jess create