Project

Profile

Help

Task #2842

Improve Pulp PyPI packages

Added by bizhang over 2 years ago. Updated 6 months ago.

Status:
MODIFIED
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
% Done:

0%

Platform Release:
Blocks Release:
Backwards Incompatible:
No
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
QA Contact:
Complexity:
Smash Test:
Verified:
No
Verification Required:
No
Sprint:
Sprint 22

Description

The current pulp packages in PyPI are not complete.

A MANIFEST.in0 file needs to be added for all PyPI packages to include external files (license)

A README.rst should be added to all PyPI packages with a nicely formatted description of the package

Some packages requres a package_data1 section in setup.py to include additional files installed in a package (config)

[0] https://packaging.python.org/tutorials/distributing-packages/#manifest-in
[1] https://packaging.python.org/tutorials/distributing-packages/#package-data

Associated revisions

Revision b4d81a1e View on GitHub
Added by werwty over 2 years ago

Update location of etc/pulp/server.yaml

re #2842
https://pulp.plan.io/issues/2842

Revision 48bcb137 View on GitHub
Added by werwty over 2 years ago

improvements to the pulpcore packages

re #2842
https://pulp.plan.io/issues/2842

Revision 48bcb137 View on GitHub
Added by werwty over 2 years ago

improvements to the pulpcore packages

re #2842
https://pulp.plan.io/issues/2842

Revision 48bcb137 View on GitHub
Added by werwty over 2 years ago

improvements to the pulpcore packages

re #2842
https://pulp.plan.io/issues/2842

History

#1 Updated by bizhang over 2 years ago

  • Sprint Candidate changed from No to Yes

#2 Updated by bmbouter over 2 years ago

+1 to config, license, and docs. We need to disinclude the systemd parts because that is OS specific, so we can't ship it with the pure Python code. I think the Ansible installer will allow the "right thing" to be done on all the different OS's. So I imagine #2840 will handle installing the systemd units.

Note that the develop install roles (not #2840) will still install the systemd unit files since the development OS is Fedora. I think they should do that if they don't already.

#3 Updated by bmbouter over 2 years ago

Actually I'm not entirely sure how to ship the docs. Maybe we should leave those out for now too?

#4 Updated by bizhang over 2 years ago

  • Description updated (diff)

I've removed docs and systemd.
There are examples of including docs in the MANIFEST.in file [0], but I am not sure if this should be done for pulp.

[0] http://python-packaging.readthedocs.io/en/latest/non-code-files.html

#5 Updated by bmbouter over 2 years ago

I don't have much experience with this, but from reading the docs, if we include them in MANIFEST.in they will install in the package's folder in site-packages. That would make that server.yaml file to install in /usr/lib/python3.5/site-packages/pulp/server.yaml.

Is there any way for us to specify that it live somewhere else in the filesystem?

#6 Updated by bizhang over 2 years ago

That can be done with the data_files option in setup.py [0] However if we were to install it directly to /etc/pulp/server.yaml pip install would require sudo permissions.

I was thinking that if we include it in the MANIFEST.in the user would install it to {venv}/usr/lib/python3.5/site-packages/pulpcore/server.yaml
they can set a environmental variable to read it from there [1]

[0] https://packaging.python.org/tutorials/distributing-packages/#data-files
[1] https://pulp.plan.io/issues/2833

#7 Updated by bizhang over 2 years ago

  • Description updated (diff)

#8 Updated by bizhang over 2 years ago

The config file should be included in the package_data instead of the MANIFEST.in since it should be included in the package and not just source distribution.

#9 Updated by bmbouter over 2 years ago

  • Groomed changed from No to Yes

Thanks @bizhang. Having it install in the python package root for pulp sounds fine. It's so cross platform! Thank you for writing this all up.

#10 Updated by mhrivnak over 2 years ago

  • Sprint/Milestone set to 41

#11 Updated by bizhang over 2 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to bizhang

#12 Updated by bizhang over 2 years ago

PR for core, common, and plugin: https://github.com/pulp/pulp/pull/3070/

#13 Updated by bizhang over 2 years ago

  • Status changed from ASSIGNED to POST

#14 Updated by bizhang over 2 years ago

  • Status changed from POST to MODIFIED

I updated the pulpcore, pulpcore-common, pulpcore-plugin, and pulp_file packages. The rest are not currently built for pypi yet and should be done at a later date.

#15 Updated by bmbouter over 1 year ago

  • Sprint set to Sprint 22

#16 Updated by bmbouter over 1 year ago

  • Sprint/Milestone deleted (41)

#17 Updated by daviddavis 6 months ago

  • Sprint/Milestone set to 3.0

#18 Updated by bmbouter 6 months ago

  • Tags deleted (Pulp 3)

Please register to edit this issue

Also available in: Atom PDF