-
-
Notifications
You must be signed in to change notification settings - Fork 745
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
[WIP] Setuptools packaging improvements - make each st2 component packagable and installable via package #1673
Conversation
…to dennybaa-setuptools-fixes
…ements to preserve a stable order.
…e common code to "dist_utils.py" module and copy this module over to each component package directory during build step. Update affected code.
…es to each component package directory.
…posed from README and CHANGELOG file.
…or each st2 component.
st2_version file. Note: For now we just copy over global __init__.py from st2common during build preparation step.
…ents.txt file for all the components.
Setuptools packaging improvements - make each st2 component packagable and installable via package
…in each component directory.
…ways use correct and latest version of pip. Also update virtualenv target to install latest version of pip instead of doing it in the requirements target.
…y so it doesn't include changelog in the package description.
@dennybaa See the pull request description above. I had a really bad time with it. There is a lot more of work which needs to be done making sure everything works end to end. Among other things, we need to get ride of recursive-include abuse in MANIFEST.in - using "*" means it will also try to include *.pyc and other files which are created while running As noted in your other PR, we should explicitly collect Python package and module files inside setup.py and only include LICENSE, templates and files like that inside |
requirements.txt.
… target also works locally in a vagrant vm.
I managed to get Before merging anything, I would like to run all the workflows on this branch and make sure everything works. @DoriftoShoes what's the easiest way to do this right now? |
|
@DoriftoShoes I tried building the packages locally in the VM (I installed all the dependencies) and everything worked fine. I would like to run all the workflows which run when we merged a branch into master. I did merge branch into master yesterday after everything worked locally, but things exploded on the CI so I would like to make sure everything works before merging the branch and breaking everything (I needed to do a force revert yesterday). |
This pull requests builds on top of of #1647 and #1668.
I spent a lot of time finishing, polishing and testing all the changes from #1668 locally. Everything worked and looked fine so I decided to merge it into master. Sadly this turned out to be a mistake - there were many, many issues with packaging and other workflows used by our CI.
After 3-4 hours of digging in and fixing issues, I still haven't managed to fix all of them so I decided to revert changes in the master and unbreak it. I believe that's better than trying to rush to whole thing. Next step will be to address all the issues and run all the packaging and related workflows on this branch and only merge it into master when everything passes.
I will work with / ask @DoriftoShoes for help with running everything on a particular branch (not sure if we are there yet, might require some changes).
The biggest offenders currently are:
MANIFEST.in
and replacing it with collecting all the code packages inside thesetup.py
files.This branch includes the following changes and improvements:
dist_utils.py
module which is copied over to each component during build step and used inside setup.py instead of copy and pasting code over in setup.py.license
andurl
attribute.long_description
attribute to each setup.py file. This attribute is generated by combining togetherREADME.rest
andCHANGELOG.rst
file.sdist
Makefilet target which generates.tar.gz
andwheel
archive for each component.__version
attribute from each package init.py file. For now we simply copy over init.py from st2common. This way we don't break out existing release / build workflow, but eventually we should move to per-package version.flask
,flask_json
. This was actually done by @dennybaa, but I verified the changes and I'm pointing it out there to make it easier to track.requirements.txt
file. This way we make sure generated requirements files are always sorted the same.TODO: