classification
Title: Python 3.6.0b4 64-bit has no sys._mercurial info
Type: compile error Stage: resolved
Components: Windows Versions: Python 3.7, Python 3.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: steve.dower Nosy List: SilentGhost, larry, ned.deily, paul.moore, python-dev, steve.dower, tim.golden, zach.ware
Priority: release blocker Keywords: patch

Created on 2016-11-01 04:41 by steve.dower, last changed 2016-11-22 19:50 by steve.dower. This issue is now closed.

Files
File name Uploaded Description Edit
28573_1.patch steve.dower, 2016-11-22 19:46 review
Messages (10)
msg279848 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-01 04:41
The release build for 3.6.0b3 64-bit is missing Mercurial info:

>>> import sys
>>> sys._mercurial
('CPython', '', '')
>>> sys.version
'3.6.0b3 (default, Nov  1 2016, 03:21:01) [MSC v.1900 64 bit (AMD64)]'

The debug build and the 32-bit builds are fine. It needs further investigation, but I assume the PGO build is to blame, as we only run PGO on the 64-bit release build.
msg279874 - (view) Author: SilentGhost (SilentGhost) * (Python triager) Date: 2016-11-01 12:16
The same is on 3.5.2 on ubuntu 16.10
msg279875 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-01 13:07
We're not responsible for the builds released by Linux distros. There's a good chance they didn't build from mercurial, but used the source release plus patches.
msg280817 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-11-15 00:17
New changeset 25cb7df5b19d by Steve Dower in branch '3.6':
Issue #28573: Avoid setting up env too many times during build
https://hg.python.org/cpython/rev/25cb7df5b19d

New changeset ae8f525cef2a by Steve Dower in branch 'default':
Issue #28573: Avoid setting up env too many times during build
https://hg.python.org/cpython/rev/ae8f525cef2a
msg280818 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-15 00:20
I suspect this is because my PATH was getting too long within my build script because of setting up the VS build environment too many times (if PATH gets too long then new processes may ignore or truncate it).

The commit should cut this down to the point where we don't lose Mercurial off of PATH, but I'm running validation builds to be sure.

As this only applies to the Windows builds and we haven't seen it against 3.5 yet, I'm dropping that from the versions list.
msg280819 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-11-15 01:52
New changeset d997e64130bd by Steve Dower in branch '3.6':
Issue #28573: Fixes issue with nested if blocks
https://hg.python.org/cpython/rev/d997e64130bd

New changeset 35f510158490 by Steve Dower in branch 'default':
Issue #28573: Fixes issue with nested if blocks
https://hg.python.org/cpython/rev/35f510158490
msg281437 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-22 06:07
Wasn't fixed as well as I'd like, so I clearly need a better approach here.
msg281506 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-22 19:46
Attaching the patch here for visibility.

In short, rather than relying on PATH to find hg.exe, we now precalculate it and pass it in to the build. This completely avoids the problem where modifying PATH multiple times for different builds was causing Mercurial to fall off.

This patch also fixes two other issues with my build script - the PGOOPTS need to come before CERTOPTS, as they are parsed by different scripts, and the debug build command fell off somewhere which resulted in the debug builds not being rebuilt for 3.6.0b4 - they are still the 3.6.0b3 debug build.
msg281507 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-11-22 19:49
New changeset 089886be06df by Steve Dower in branch '3.6':
Issue #28573: Missing sys._mercurial info and other build issues.
https://hg.python.org/cpython/rev/089886be06df

New changeset d0958078bcb6 by Steve Dower in branch 'default':
Issue #28573: Missing sys._mercurial info and other build issues.
https://hg.python.org/cpython/rev/d0958078bcb6
msg281508 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2016-11-22 19:50
Ned approved this last night on IRC, so now it's in.
History
Date User Action Args
2016-11-22 19:50:01steve.dowersetstatus: open -> closed
resolution: fixed
messages: + msg281508

stage: resolved
2016-11-22 19:49:41python-devsetmessages: + msg281507
2016-11-22 19:46:50steve.dowersetfiles: + 28573_1.patch
keywords: + patch
messages: + msg281506
2016-11-22 06:07:42steve.dowersetstatus: closed -> open
title: Python 3.6.0b3 64-bit has no sys._mercurial info -> Python 3.6.0b4 64-bit has no sys._mercurial info
messages: + msg281437

resolution: fixed -> (no value)
stage: resolved -> (no value)
2016-11-15 01:52:40steve.dowersetstatus: open -> closed
resolution: fixed
stage: commit review -> resolved
2016-11-15 01:52:04python-devsetmessages: + msg280819
2016-11-15 00:20:38steve.dowersetstage: test needed -> commit review
messages: + msg280818
versions: - Python 3.5
2016-11-15 00:17:12python-devsetnosy: + python-dev
messages: + msg280817
2016-11-01 13:07:54steve.dowersetmessages: + msg279875
2016-11-01 12:16:23SilentGhostsetnosy: + larry, SilentGhost

messages: + msg279874
versions: + Python 3.5
2016-11-01 04:41:03steve.dowercreate