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_gdb failed #73871

Closed
MarcoC mannequin opened this issue Mar 1, 2017 · 3 comments
Closed

test_gdb failed #73871

MarcoC mannequin opened this issue Mar 1, 2017 · 3 comments
Labels
build The build process and cross-build tests Tests in the Lib/test dir

Comments

@MarcoC
Copy link
Mannequin

MarcoC mannequin commented Mar 1, 2017

BPO 29685
Nosy @vstinner, @tirkarthi
Superseder
  • bpo-40436: pythoninfo collect_gdb() blows up when gdb fails to run
  • 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 2020-06-11.13:22:55.823>
    created_at = <Date 2017-03-01.15:42:34.511>
    labels = ['build', 'tests']
    title = 'test_gdb failed'
    updated_at = <Date 2020-06-11.13:22:55.822>
    user = 'https://bugs.python.org/MarcoC'

    bugs.python.org fields:

    activity = <Date 2020-06-11.13:22:55.822>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2020-06-11.13:22:55.823>
    closer = 'vstinner'
    components = ['Tests']
    creation = <Date 2017-03-01.15:42:34.511>
    creator = 'MarcoC'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 29685
    keywords = []
    message_count = 3.0
    messages = ['288760', '326207', '371275']
    nosy_count = 3.0
    nosy_names = ['vstinner', 'MarcoC', 'xtreak']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = '40436'
    type = 'compile error'
    url = 'https://bugs.python.org/issue29685'
    versions = ['Python 3.6']

    @MarcoC
    Copy link
    Mannequin Author

    MarcoC mannequin commented Mar 1, 2017

    make test output

    studio@linux:~/Python-3.6.0> ./python -m test -v test_gdb
    == CPython 3.6.0 (default, Mar 1 2017, 15:51:48) [GCC 4.8.5]
    ==   Linux-4.4.49-16-default-x86_64-with-SuSE-42.2-x86_64 little-endian
    ==   hash algorithm: siphash24 64bit
    ==  cwd: /home/studio/Python-3.6.0/build/test_python_32667
    ==  encodings: locale=UTF-8, FS=utf-8
    Testing with flags: sys.flags(debug=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, no_user_site=0, no_site=0, ignore_environment=0, verbose=0, bytes_warning=0, quiet=0, hash_randomization=1, isolated=0)
    Run tests sequentially
    0:00:00 [1/1] test_gdb
    test test_gdb crashed -- Traceback (most recent call last):
      File "/home/studio/Python-3.6.0/Lib/test/libregrtest/runtest.py", line 152, in runtest_inner
        the_module = importlib.import_module(abstest)
      File "/home/studio/Python-3.6.0/Lib/importlib/__init__.py", line 126, in import_module
        return _bootstrap._gcd_import(name[level:], package, level)
      File "<frozen importlib._bootstrap>", line 978, in _gcd_import
      File "<frozen importlib._bootstrap>", line 961, in _find_and_load
      File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked
      File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
      File "<frozen importlib._bootstrap_external>", line 678, in exec_module
      File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
      File "/home/studio/Python-3.6.0/Lib/test/test_gdb.py", line 46, in <module>
        gdb_version, gdb_major_version, gdb_minor_version = get_gdb_version()
      File "/home/studio/Python-3.6.0/Lib/test/test_gdb.py", line 43, in get_gdb_version
        raise Exception("unable to parse GDB version: %r" % version)
    Exception: unable to parse GDB version: ''

    test_gdb failed

    1 test failed:
    test_gdb

    Total duration: 31 ms
    Tests result: FAILURE

    @MarcoC MarcoC mannequin added tests Tests in the Lib/test dir build The build process and cross-build labels Mar 1, 2017
    @tirkarthi
    Copy link
    Member

    Can you please add your GDB version? The version parsing is done with regex r"^GNU gdb.*?\b(\d+).(\d+)" and I think it's not matching your version which seems to be empty. Adding the output of gdb -nx --version will be helpful in debugging this since the output is the string used against the regex.

    Thanks

    @vstinner
    Copy link
    Member

    I believe that this issue is a duplicated of bpo-40436 which was fixed by:

    commit ec9bea4
    Author: Victor Stinner <vstinner@python.org>
    Date: Wed Apr 29 17:11:48 2020 +0200

    bpo-40436: Fix code parsing gdb version (GH-19792)
    
    test_gdb and test.pythoninfo now check gdb command exit code.
    

    If it's not the case, please provide more information, as requested.

    @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
    build The build process and cross-build tests Tests in the Lib/test dir
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants