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

Package name is missing in XML report. #235

Closed
nedbat opened this issue Feb 13, 2013 · 12 comments
Closed

Package name is missing in XML report. #235

nedbat opened this issue Feb 13, 2013 · 12 comments
Labels
bug Something isn't working xml

Comments

@nedbat
Copy link
Owner

nedbat commented Feb 13, 2013

Originally reported by schlauch (Bitbucket: schlauch, GitHub: schlauch)


Since 3.6 the package name is missing. I think the problem is the optimization of the package name. See xmlreport.py line 95 (xml_file):

  • The cu.name is a file path in my case (e.g., src\sample_calculator_init_)
  • rparition goes wrong => creates an empty string because cu.name has no "."
    I used coverage.py 3.6 on Windows 7 with Python 2.7.3

In 3.5 os.path.split has been used... However, this has been removed by commit:
https://bitbucket.org/ned/coveragepy/commits/6af3ba6d47e49420662c5e9f2d37f0f479ae6949


@nedbat
Copy link
Owner Author

nedbat commented Feb 13, 2013

Can you provide a test case that demonstrates the regression?

@nedbat
Copy link
Owner Author

nedbat commented Feb 14, 2013

Original comment by schlauch (Bitbucket: schlauch, GitHub: schlauch)


I attached a small project which illustrates the problem. It also contains the coverage XML reports which I created with version 3.5.3 and 3.6.:
The problem is the name attribute in the package tag.

For more information see the README.txt.

@nedbat
Copy link
Owner Author

nedbat commented Dec 9, 2013

Original comment by Camilo Nova (Bitbucket: camilonova, GitHub: camilonova)


Also happens to me as well for versions 3.6 and 3.7

issue

@nedbat
Copy link
Owner Author

nedbat commented Dec 9, 2013

Original comment by Lex Berezhny (Bitbucket: eukreign, GitHub: eukreign)


@camilonova try my pull request #28 it resolves this issue and also adds support for defining package depth

@nedbat
Copy link
Owner Author

nedbat commented Mar 5, 2014

Original comment by Matt Wright (Bitbucket: mattupstate, GitHub: mattupstate)


I just downgraded from 3.7.1 to 3.5.0. With 3.7.1, package name was missing. With 3.5.0, package name was _not_missing.

@nedbat
Copy link
Owner Author

nedbat commented Mar 29, 2014

Original comment by Camilo Nova (Bitbucket: camilonova, GitHub: camilonova)


@nedbat Can you take a look again at this issue? seems https://bitbucket.org/ned/coveragepy/pull-request/28/package-depth-for-xml-report fixes it.

@nedbat
Copy link
Owner Author

nedbat commented Apr 7, 2014

Original comment by Camilo Nova (Bitbucket: camilonova, GitHub: camilonova)


@nedbat the pull request was updated so it can be easily integrated. Will be great if you take and action soon on this mayor bug to fix it.

@nedbat
Copy link
Owner Author

nedbat commented Oct 23, 2014

Original comment by Camilo Nova (Bitbucket: camilonova, GitHub: camilonova)


@nedbat do you have any updates on this?

@nedbat
Copy link
Owner Author

nedbat commented Jan 19, 2015

Everyone, sorry for the ridiculous regression, and for not attending to it sooner. This is now fixed in fa3b3f5777d0 (bb).

@nedbat
Copy link
Owner Author

nedbat commented Jan 20, 2015

Original comment by Camilo Nova (Bitbucket: camilonova, GitHub: camilonova)


Thank you, can you put it on pypi ?

@nedbat
Copy link
Owner Author

nedbat commented Jan 20, 2015

Original comment by schlauch (Bitbucket: schlauch, GitHub: schlauch)


Great to see that this issue is finally fixed :) Thanks!

@nedbat
Copy link
Owner Author

nedbat commented Jan 21, 2015

Sure, here it is: https://pypi.python.org/pypi/coverage/4.0a3

@nedbat nedbat closed this as completed Jan 21, 2015
@nedbat nedbat added major bug Something isn't working xml labels Jun 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working xml
Projects
None yet
Development

No branches or pull requests

1 participant