Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.6.0b4 64-bit has no sys._mercurial info #72759

Closed
zooba opened this issue Nov 1, 2016 · 10 comments
Closed

Python 3.6.0b4 64-bit has no sys._mercurial info #72759

zooba opened this issue Nov 1, 2016 · 10 comments
Assignees
Labels
3.7 (EOL) end of life build The build process and cross-build OS-windows release-blocker

Comments

@zooba
Copy link
Member

zooba commented Nov 1, 2016

BPO 28573
Nosy @pfmoore, @larryhastings, @tjguk, @ned-deily, @zware, @zooba
Files
  • 28573_1.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/zooba'
    closed_at = <Date 2016-11-22.19:50:01.750>
    created_at = <Date 2016-11-01.04:41:03.236>
    labels = ['build', '3.7', 'OS-windows', 'release-blocker']
    title = 'Python 3.6.0b4 64-bit has no sys._mercurial info'
    updated_at = <Date 2016-11-22.19:50:01.749>
    user = 'https://github.com/zooba'

    bugs.python.org fields:

    activity = <Date 2016-11-22.19:50:01.749>
    actor = 'steve.dower'
    assignee = 'steve.dower'
    closed = True
    closed_date = <Date 2016-11-22.19:50:01.750>
    closer = 'steve.dower'
    components = ['Windows']
    creation = <Date 2016-11-01.04:41:03.236>
    creator = 'steve.dower'
    dependencies = []
    files = ['45605']
    hgrepos = []
    issue_num = 28573
    keywords = ['patch']
    message_count = 10.0
    messages = ['279848', '279874', '279875', '280817', '280818', '280819', '281437', '281506', '281507', '281508']
    nosy_count = 8.0
    nosy_names = ['paul.moore', 'larry', 'tim.golden', 'ned.deily', 'SilentGhost', 'python-dev', 'zach.ware', 'steve.dower']
    pr_nums = []
    priority = 'release blocker'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'compile error'
    url = 'https://bugs.python.org/issue28573'
    versions = ['Python 3.6', 'Python 3.7']

    @zooba
    Copy link
    Member Author

    zooba commented Nov 1, 2016

    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.

    @zooba zooba self-assigned this Nov 1, 2016
    @zooba zooba added OS-windows build The build process and cross-build labels Nov 1, 2016
    @SilentGhost
    Copy link
    Mannequin

    SilentGhost mannequin commented Nov 1, 2016

    The same is on 3.5.2 on ubuntu 16.10

    @zooba
    Copy link
    Member Author

    zooba commented Nov 1, 2016

    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.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Nov 15, 2016

    New changeset 25cb7df5b19d by Steve Dower in branch '3.6':
    Issue bpo-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 bpo-28573: Avoid setting up env too many times during build
    https://hg.python.org/cpython/rev/ae8f525cef2a

    @zooba
    Copy link
    Member Author

    zooba commented Nov 15, 2016

    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.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Nov 15, 2016

    New changeset d997e64130bd by Steve Dower in branch '3.6':
    Issue bpo-28573: Fixes issue with nested if blocks
    https://hg.python.org/cpython/rev/d997e64130bd

    New changeset 35f510158490 by Steve Dower in branch 'default':
    Issue bpo-28573: Fixes issue with nested if blocks
    https://hg.python.org/cpython/rev/35f510158490

    @zooba zooba closed this as completed Nov 15, 2016
    @zooba
    Copy link
    Member Author

    zooba commented Nov 22, 2016

    Wasn't fixed as well as I'd like, so I clearly need a better approach here.

    @zooba zooba reopened this Nov 22, 2016
    @zooba zooba changed the title Python 3.6.0b3 64-bit has no sys._mercurial info Python 3.6.0b4 64-bit has no sys._mercurial info Nov 22, 2016
    @zooba
    Copy link
    Member Author

    zooba commented Nov 22, 2016

    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.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Nov 22, 2016

    New changeset 089886be06df by Steve Dower in branch '3.6':
    Issue bpo-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 bpo-28573: Missing sys._mercurial info and other build issues.
    https://hg.python.org/cpython/rev/d0958078bcb6

    @zooba
    Copy link
    Member Author

    zooba commented Nov 22, 2016

    Ned approved this last night on IRC, so now it's in.

    @zooba zooba closed this as completed Nov 22, 2016
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.7 (EOL) end of life build The build process and cross-build OS-windows release-blocker
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant