-
Notifications
You must be signed in to change notification settings - Fork 39
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
Coverage parsing speedup #151
Conversation
@@ -40,6 +39,9 @@ install_requires = | |||
tabulate | |||
ruamel.yaml | |||
|
|||
[options.package_data] | |||
* = *.jinja2, *.css |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without this change, installing from archive misses the package data files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gro1m I'm less familiar with this part, any concerns?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@oev81 what did you observe? What do you mean by "installing from archive"? Do you mean from a zip file instead of pip install pycobertura
? What was your process to get an archive?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gro1m I'm less familiar with this part, any concerns?
This is about data file support.
In this case all jinja2
and css
files are included as well and not only the Python files.
Concretely, this means when installing pycobertura, we have also access to the following files in the templates
folder:
html.jinja2
html-delta.jinja2
normalize.css
As we have this under control, this should not be a security issue, but rather an improvement. Probably some html rendering did not work properly before in all cases, as include_package_date=True
would have required an additional MANIFEST.in
file (see also the reference link below).
Data File Support Reference (even if for setup.py
instead of setup.cfg
, but this analogue): https://setuptools.pypa.io/en/latest/userguide/datafiles.html
Hope this is clearer now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aconrad
You can install package directly from github as an archive
pip install https://github.com/oev81/pycobertura/archive/coverage_parsing_speedup.zip
or put
https://github.com/oev81/pycobertura/archive/coverage_parsing_speedup.zip
in requirements.txt
This way is very helpful for me. https://stackoverflow.com/a/24811490
@aconrad Could you please review? This looks helpful... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you pull the latest master into your branch so we can see what the |
Can you also update the CHANGES file with a note about the fix? Feel free to tag yourself (see other entries as an example) |
@@ -20,6 +20,9 @@ | |||
* Replace Travis-ci with Github Actions. We were having issues with Travis | |||
pipeline not triggering because of quota issues. | |||
|
|||
* Changes in Cobertura class. All `"./packages//class"` elements extracted at once now, and this leads to significant speedup. | |||
* Changes in setup.cfg related to package data. Remove `include_package_data=True`, because it requires `MANIFEST.in` and add `[options.package_data]` instead. This change makes the package installing from archive not miss `*.css` and `*.jinja2` files. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is some pretty sweet changelog, thank you for doing that!
No description provided.