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

test_builtin fails after merging the fix for bpo-34756 #79923

Closed
yan12125 mannequin opened this issue Jan 15, 2019 · 10 comments
Closed

test_builtin fails after merging the fix for bpo-34756 #79923

yan12125 mannequin opened this issue Jan 15, 2019 · 10 comments
Labels
3.8 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error

Comments

@yan12125
Copy link
Mannequin

yan12125 mannequin commented Jan 15, 2019

BPO 35742
Nosy @vstinner, @serhiy-storchaka, @yan12125, @miss-islington
PRs
  • bpo-35742: Fix test_envar_unimportable in test_builtin. #11561
  • bpo-35742: Fix test_envar_unimportable in test_builtin. #11561
  • bpo-35742: Fix test_envar_unimportable in test_builtin. #11561
  • bpo-35742: Fix test_envar_unimportable in test_builtin. #11561
  • [3.7] bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561) #11564
  • [3.7] bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561) #11564
  • [3.7] bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561) #11564
  • [3.7] bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561) #11564
  • 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 = None
    closed_at = <Date 2019-01-15.11:50:12.099>
    created_at = <Date 2019-01-15.09:43:57.778>
    labels = ['3.8', 'type-bug', 'tests']
    title = 'test_builtin fails after merging the fix for bpo-34756'
    updated_at = <Date 2019-01-15.12:02:39.172>
    user = 'https://github.com/yan12125'

    bugs.python.org fields:

    activity = <Date 2019-01-15.12:02:39.172>
    actor = 'serhiy.storchaka'
    assignee = 'none'
    closed = True
    closed_date = <Date 2019-01-15.11:50:12.099>
    closer = 'serhiy.storchaka'
    components = ['Tests']
    creation = <Date 2019-01-15.09:43:57.778>
    creator = 'yan12125'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 35742
    keywords = ['patch', 'patch', 'patch', 'patch']
    message_count = 10.0
    messages = ['333655', '333668', '333669', '333670', '333671', '333677', '333682', '333684', '333685', '333686']
    nosy_count = 4.0
    nosy_names = ['vstinner', 'serhiy.storchaka', 'yan12125', 'miss-islington']
    pr_nums = ['11561', '11561', '11561', '11561', '11564', '11564', '11564', '11564']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue35742'
    versions = ['Python 3.8']

    @yan12125
    Copy link
    Mannequin Author

    yan12125 mannequin commented Jan 15, 2019

    On git-master (32ebd85) of CPython, 3 tests of test_builtin fails:

    ======================================================================
    ERROR: test_envar_unimportable (test.test_builtin.TestBreakpoint) (envar='.')
    ----------------------------------------------------------------------

    Traceback (most recent call last):
      File "/home/yen/Projects/cpython/Lib/test/test_builtin.py", line 1618, in test_envar_unimportable
        breakpoint()
    ValueError: Empty module name

    ======================================================================
    ERROR: test_envar_unimportable (test.test_builtin.TestBreakpoint) (envar='.foo')
    ----------------------------------------------------------------------

    Traceback (most recent call last):
      File "/home/yen/Projects/cpython/Lib/test/test_builtin.py", line 1618, in test_envar_unimportable
        breakpoint()
    ValueError: Empty module name

    ======================================================================
    ERROR: test_envar_unimportable (test.test_builtin.TestBreakpoint) (envar='.int')
    ----------------------------------------------------------------------

    Traceback (most recent call last):
      File "/home/yen/Projects/cpython/Lib/test/test_builtin.py", line 1618, in test_envar_unimportable
        breakpoint()
    ValueError: Empty module name

    If I revert 6fe9c44, tests pass. This commit is from bpo-34756, so I add the author of that patch to the nosy list.

    Environment: Arch Linux x86_64

    Steps to reproduce:
    $ ./configure
    $ make
    $ ./python -m test -v test_builtin

    @yan12125 yan12125 mannequin added 3.8 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error labels Jan 15, 2019
    @yan12125
    Copy link
    Mannequin Author

    yan12125 mannequin commented Jan 15, 2019

    Wow that's super fast! I can confirm the patch fixes the issue on my machine. Thanks!

    @vstinner
    Copy link
    Member

    I don't understand why buildbots didn't scream and why the test didn't fail on Travis CI nor AppVeyor on #9457

    @yan12125
    Copy link
    Mannequin Author

    yan12125 mannequin commented Jan 15, 2019

    Found a test_builtin failure in the job for the relevant commit on Travis CI - https://travis-ci.org/python/cpython/jobs/479642964#L1491. I guess it's not noticed as it's listed in allow_failures in .travis.yml. However, I'm not sure if it's the same issue or not as there are no failure details.

    @vstinner
    Copy link
    Member

    Found a test_builtin failure in the job for the relevant commit on Travis CI - https://travis-ci.org/python/cpython/jobs/479642964#L1491.

    This job is for code coverage. I confirm that failures are allowed. This job runs the full test suite in sequence, whereas the main Travis CI job runs tests in parallel... I tested running tests in sequence and in parallel: test_builtin fail in both cases. It's a mystery. Anyway, it's going to be fixed soon ;-)

    @serhiy-storchaka
    Copy link
    Member

    New changeset 3607ef4 by Serhiy Storchaka in branch 'master':
    bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561)
    3607ef4

    @miss-islington
    Copy link
    Contributor

    New changeset 97d6a56 by Miss Islington (bot) in branch '3.7':
    bpo-35742: Fix test_envar_unimportable in test_builtin. (GH-11561)
    97d6a56

    @serhiy-storchaka
    Copy link
    Member

    I was surprised too. Maybe it is because that was very old PR.

    @vstinner
    Copy link
    Member

    I was surprised too. Maybe it is because that was very old PR.

    Yeah, that's the most likely explanation. Maybe the CI ran tests before the final merge, or something like that? It doesn't explain why buildbots didn't complain, but it doesn't matter if such hiccup is very rare ;-)

    @serhiy-storchaka
    Copy link
    Member

    Maybe CI updates only files touched by the PR and the failed test was added after the initial creation of the PR? Or there is something wrong with timestamps, so outdated pyc files were used for tests?

    @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.8 only security fixes tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants