Hide Forgot
Description of problem: An rpmdeplint run crashed when running against a set of packages with a segfault. Version-Release number of selected component (if applicable): develop HEAD How reproducible: 100%
Backtrace: { "signal": 11 , "executable": "/usr/bin/python2.7" , "only_crash_thread": true , "stacktrace": [ { "crash_thread": true , "frames": [ { "address": 140657712026468 , "build_id": "67b21091fd0c68bbad15abe60459fc21828fc2b7" , "build_id_offset": 58212 , "function_name": "hy_package_get_reponame" , "file_name": "/usr/lib64/libhawkey.so.2" } , { "address": 140657714241258 , "build_id": "cbbf0dbfa0538ff93abba410ae3887d3519e1dec" , "build_id_offset": 52970 , "function_name": "get_str" , "file_name": "/usr/lib64/python2.7/site-packages/hawkey/_hawkeymodule.so" } , { "address": 140657750259198 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 390654 , "function_name": "getset_get" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750418739 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 550195 , "function_name": "_PyObject_GenericGetAttrWithDict" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750776923 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 908379 , "function_name": "PyEval_EvalFrameEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750810716 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 942172 , "function_name": "PyEval_EvalCodeEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750798225 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 929681 , "function_name": "PyEval_EvalFrameEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750810716 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 942172 , "function_name": "PyEval_EvalCodeEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750798225 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 929681 , "function_name": "PyEval_EvalFrameEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750810716 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 942172 , "function_name": "PyEval_EvalCodeEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750798225 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 929681 , "function_name": "PyEval_EvalFrameEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750810716 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 942172 , "function_name": "PyEval_EvalCodeEx" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750810953 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 942409 , "function_name": "PyEval_EvalCode" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750914351 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 1045807 , "function_name": "run_mod" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750919010 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 1050466 , "function_name": "PyRun_FileExFlags" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750923637 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 1055093 , "function_name": "PyRun_SimpleFileExFlags" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } , { "address": 140657750997344 , "build_id": "50b7008fa405022ee9520cd3863d7572ac6a632d" , "build_id_offset": 1128800 , "function_name": "Py_Main" , "file_name": "/usr/lib64/libpython2.7.so.1.0" } ] } ] }
Thanks Jon for trying! Fedora 24, same packages you have. I reran the same test with the downloaded packages I still had on my harddisk and it segfaulted. I checksummed all these packages I had on disk and checked with the API again. The sums don't match. Perhaps I ran rpmdeplint against a bunch of garbage packages. Let me re-run again, perhaps it's a NOTABUG.
In that case I would still want to know why the packages were garbage (bug in whatever downloaded them? was it rpm-test-trigger?). Also if rpmdeplint is pointed at corrupted packages it should at least give a good error and not segfault.
Yeah I figured that half the packages where HTML pages with a 404 code in it, while the others were RPMS. I agree, a segfault is perhaps not a desired error for users :)
Python stacktrace: Traceback (most recent call first): File "/home/rjoost/works/rpmdeplint/rpmdeplint/__init__.py", line 164, in try_to_install_all logger.debug('Solving install goal for %s', pkg) File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 25, in cmd_check ok, result = analyzer.try_to_install_all() File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 195, in main parser_check_upgrade.set_defaults(func=cmd_check_upgrade) File "/home/rjoost/works/erratatrigger.buildout/bin/rpmdeplint", line 22, in <module> sys.exit(rpmdeplint.cli.main()) More detailed stacktrace in regards to hawkey: #0 0x00007fed6cf5d364 in hy_package_get_reponame (pkg=<error reading variable: value has been optimized out>) at /usr/src/debug/hawkey-0.6.3/src/package.c:317 #1 0x00007fed6d179eea in get_str (self=<optimized out>, closure=<optimized out>) at /usr/src/debug/hawkey-0.6.3/src/python/package-py.c:221 #2 0x00007fed6f3d35fe in getset_get (descr=0x7fed6d390488, obj=<_hawkey.Package at remote 0x7fed6f8e7290>, type=<optimized out>) at /usr/src/debug/Python-2.7.12/Objects/descrobject.c:146 #3 0x00007fed6f3fa533 in _PyObject_GenericGetAttrWithDict (obj=<_hawkey.Package at remote 0x7fed6f8e7290>, name='reponame', dict=0x0) at /usr/src/debug/Python-2.7.12/Objects/object.c:1439 after running: gdb /usr/bin/python2.7 coredump and installing most of the debuginfo packages for python2 and hawkey
(In reply to Roman Joost from comment #8) > Python stacktrace: > > Traceback (most recent call first): > File "/home/rjoost/works/rpmdeplint/rpmdeplint/__init__.py", line 164, in > try_to_install_all > logger.debug('Solving install goal for %s', pkg) > File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 25, in > cmd_check > ok, result = analyzer.try_to_install_all() > File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 195, in main > parser_check_upgrade.set_defaults(func=cmd_check_upgrade) > File "/home/rjoost/works/erratatrigger.buildout/bin/rpmdeplint", line 22, > in <module> > sys.exit(rpmdeplint.cli.main()) This stack trace appears to be gibberish (set_defaults obviously doesn't call into cmd_check) which is probably because you have updated your git checkout since the coredump was produced. So now the line numbers in the source files on disk don't match up. If you could regenerate this with the matching Python source files in place that would be helpful.
(In reply to Dan Callaghan from comment #9) Actually never mind this. I think we can trust the function names, since they are extracted by gdb from Python interpreter locals... in which case the only wrong frame in the stack trace is: File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 195, in main parser_check_upgrade.set_defaults(func=cmd_check_upgrade) which should actually be: File "/home/rjoost/works/rpmdeplint/rpmdeplint/cli.py", line 195, in main return args.func(args) assuming you were using rpmdeplint 1.1.
Filed a hawkey bug for this: bug 1383565. I reproduced it with this rpmdeplint acceptance test (this is just the test, not a fix, so we can't merge it because it is expected to fail): http://gerrit.beaker-project.org/5306 I will see about whipping up a patch for hawkey in order to increase our chances of it getting fixed...
Closing this as CANTFIX in the sense that there is nothing reasonable we can do in rpmdeplint to avoid this -- it will need to be fixed in hawkey. I have attached a patch with test case on the hawkey bug 1383565 so hopefully it will be fixed soon. We can either just discard the rpmdeplint reproducer in comment 11, or merge it when (if) the hawkey fix lands in all distros which we are targetting...