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

gcov: accommodate the execution_count format change in GCC 8.1 #127

Merged
merged 1 commit into from
Jul 6, 2018

Conversation

ueno
Copy link
Contributor

@ueno ueno commented Jun 27, 2018

The format of gcov's execution_count has been extended to indicate any
unexecuted blocks in a single line, with a following '*':
gcc-mirror/gcc@3cf7fdd

This confuses cpp-coveralls and leads to a parsing error:

Traceback (most recent call last):
[...]
    coverage.append(int(cov_num))
ValueError: invalid literal for int() with base 10: '2*'

The format of gcov's execution_count has been extended to indicate any
unexecuted blocks in a single line, with a following '*':
gcc-mirror/gcc@3cf7fdd

This confuses cpp-coveralls and leads to a parsing error:

Traceback (most recent call last):
[...]
    coverage.append(int(cov_num))
ValueError: invalid literal for int() with base 10: '2*'
@dbeurle
Copy link

dbeurle commented Jun 27, 2018

Is this potentially related to #126? I've seen this error too using GCC 8.1.

@chrisosaurus
Copy link
Collaborator

The Travis build error is unrelated to this change

https://travis-ci.org/eddyxu/cpp-coveralls/jobs/397341693#L491

RuntimeError: cryptography requires setuptools 18.5 or newer, please upgrade to a newer version of setuptools

which only happens on Python 3.3

This change passes on Python 2.7, 3.4, 3.5, and pypy.

@chrisosaurus
Copy link
Collaborator

Thanks for providing the link to the upstream change, merging now as it seems safe.

Ideally we should add some unit testing (using example gcov outputs), but such is life.

@chrisosaurus chrisosaurus merged commit 0e56fb6 into eddyxu:master Jul 6, 2018
ueno added a commit to ueno/p11-kit that referenced this pull request Aug 24, 2018
To accommodate the gcov format change in gcc 8.1:
eddyxu/cpp-coveralls#127
which is not yet available in the pip version.
ueno added a commit to ueno/p11-kit that referenced this pull request Aug 27, 2018
To accommodate the gcov format change in gcc 8.1:
eddyxu/cpp-coveralls#127
which is not yet available in the pip version.
ueno added a commit to p11-glue/p11-kit that referenced this pull request Aug 28, 2018
To accommodate the gcov format change in gcc 8.1:
eddyxu/cpp-coveralls#127
which is not yet available in the pip version.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants