Bug 1567948

Summary: [abrt] gcovr: process_gcov_data(): gcovr:632:process_gcov_data:ValueError: invalid literal for int() with base 10: '2605*'
Product: [Fedora] Fedora Reporter: Stephen Gallagher <sgallagh>
Component: gcovrAssignee: Neal Gompa <ngompa13>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: ckellner, ngompa13, philip.salvaggio
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
URL: https://retrace.fedoraproject.org/faf/reports/bthash/b05d9b3d56d5ed5d447cf6ed7c9525b39e793ed5
Whiteboard: abrt_hash:60884d44a121586ee7e2327a47fb767975cb339d;VARIANT_ID=workstation;
Fixed In Version: gcovr-4.1-2.fc28 gcovr-4.1-2.fc29 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-09-17 03:55:10 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File: backtrace
none
File: cgroup
none
File: cpuinfo
none
File: environ
none
File: mountinfo
none
File: namespaces
none
File: open_fds none

Description Stephen Gallagher 2018-04-16 13:24:04 UTC
Description of problem:
I attempted to run `ninja coverage` against libmodulemd using meson, configured with `-Db_coverage=true`.

Version-Release number of selected component:
gcovr-3.3-6.fc28

Additional info:
reporter:       libreport-2.9.4
cmdline:        /usr/bin/python3 -s /usr/bin/gcovr -x -r /home/sgallagh/workspace/libmodulemd -o /home/sgallagh/workspace/libmodulemd/x86_64/meson-logs/coverage.xml
crash_function: process_gcov_data
exception_type: ValueError
executable:     /usr/bin/gcovr
interpreter:    python3-3.6.5-1.fc28.x86_64
kernel:         4.16.1-300.fc28.x86_64
runlevel:       N 5
type:           Python3
uid:            13041

Truncated backtrace:
gcovr:632:process_gcov_data:ValueError: invalid literal for int() with base 10: '2605*'

Traceback (most recent call last):
  File "/usr/bin/gcovr", line 2318, in <module>
    process_datafile(file_, covdata, options)
  File "/usr/bin/gcovr", line 897, in process_datafile
    process_gcov_data(fname, covdata, abs_filename, options)
  File "/usr/bin/gcovr", line 632, in process_gcov_data
    covered[lineno] = int(segments[0].strip())
ValueError: invalid literal for int() with base 10: '2605*'

Local variables in innermost frame:
code: ''
is_code_statement: True
tmp: '2605*'
last_code_line_excluded: False
last_code_lineno: 103
last_code_line: '\n'
lineno: 104
branches: {}
covered: {}
uncovered_exceptional: set()
uncovered: set()
noncode: {32, 65, 34, 66, 36, 69, 70, 102, 72, 103, 74, 24, 63}
excluding: []
i: 0
filtered_fname: 'x86_64/modulemd/modulemd@sha/modulemd-module.c'
fname: '/home/sgallagh/workspace/libmodulemd/x86_64/modulemd/modulemd@sha/modulemd-module.c'
root_dir: '/home/sgallagh/workspace/libmodulemd'
currdir: '/home/sgallagh/workspace/libmodulemd/x86_64'
segments: ['    2605*', '  104', 'G_DEFINE_TYPE (ModulemdModule, modulemd_module, G_TYPE_OBJECT)\n']
line: '    2605*:  104:G_DEFINE_TYPE (ModulemdModule, modulemd_module, G_TYPE_OBJECT)\n'
INPUT: <_io.TextIOWrapper name='^#modulemd#modulemd-module.c.gcov' mode='r' encoding='UTF-8'>
options: <Values at 0x7f980b377cf8: {'version': False, 'verbose': False, 'objdir': None, 'output': '/home/sgallagh/workspace/libmodulemd/x86_64/meson-logs/coverage.xml', 'keep': False, 'delete': False, 'filter': [re.compile('\\/home\\/sgallagh\\/workspace\\/libmodulemd\\/')], 'exclude': [], 'gcov_filter': re.compile(''), 'gcov_exclude': [], 'root': '/home/sgallagh/workspace/libmodulemd', 'xml': True, 'prettyxml': False, 'html': False, 'html_details': False, 'relative_anchors': True, 'show_branch': None, 'sort_uncovered': None, 'sort_percent': None, 'gcov_cmd': 'gcov', 'exclude_unreachable_branches': False, 'exclude_dirs': [], 'gcov_files': False, 'print_summary': False, 'root_filter': re.compile('\\/home\\/sgallagh\\/workspace\\/libmodulemd\\/')}>
source_fname: '/home/sgallagh/workspace/libmodulemd/x86_64/modulemd/modulemd@sha/modulemd-module.c.gcda'
covdata: {}
data_fname: '^#modulemd#modulemd-module.c.gcov'

Comment 1 Stephen Gallagher 2018-04-16 13:24:09 UTC
Created attachment 1422484 [details]
File: backtrace

Comment 2 Stephen Gallagher 2018-04-16 13:24:10 UTC
Created attachment 1422485 [details]
File: cgroup

Comment 3 Stephen Gallagher 2018-04-16 13:24:11 UTC
Created attachment 1422486 [details]
File: cpuinfo

Comment 4 Stephen Gallagher 2018-04-16 13:24:12 UTC
Created attachment 1422487 [details]
File: environ

Comment 5 Stephen Gallagher 2018-04-16 13:24:13 UTC
Created attachment 1422488 [details]
File: mountinfo

Comment 6 Stephen Gallagher 2018-04-16 13:24:14 UTC
Created attachment 1422489 [details]
File: namespaces

Comment 7 Stephen Gallagher 2018-04-16 13:24:15 UTC
Created attachment 1422490 [details]
File: open_fds

Comment 8 Philip Salvaggio 2018-07-16 14:28:18 UTC
I am also seeing this error. I think this should probably be reported on the gcovr github page rather than here though.

Comment 9 Philip Salvaggio 2018-07-16 15:54:33 UTC
After some investigation, the issue appears to be that the gcovr version in dnf is out of date, in order to work with GCC 8, you need to be using GCOVR 4.0. If you install gcovr through pip instead of dnf, it has the latest version. The RPM should be upgraded too, though.

Comment 10 Fedora Update System 2018-09-07 19:30:33 UTC
gcovr-4.1-2.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-51bcb5bb98

Comment 11 Fedora Update System 2018-09-07 19:31:13 UTC
gcovr-4.1-2.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-9da74c592f

Comment 12 Fedora Update System 2018-09-07 22:49:15 UTC
gcovr-4.1-2.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-51bcb5bb98

Comment 13 Fedora Update System 2018-09-09 09:19:39 UTC
gcovr-4.1-2.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-9da74c592f

Comment 14 Fedora Update System 2018-09-17 03:55:10 UTC
gcovr-4.1-2.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.

Comment 15 Fedora Update System 2018-09-21 05:30:03 UTC
gcovr-4.1-2.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.