-
-
Notifications
You must be signed in to change notification settings - Fork 764
Include requirements.txt files for all the components Python packages #4751
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
Conversation
This way Python packages are valid and can be re-used from other places.
This makes them valid Python packages.
are valid. Run it on Travis.
components Python package checks.
If kill_func() is called there is a possible race where run_command() will return before kill_func() finishes and as such, process.returncode won't be set. This happens because kill_func is async.
As a "bonus", I also fixed intermediate test failure / race which has been happening for a long time - https://gist.github.com/Kami/83ee1d430a2366b3656fa2d28286f810. This race happens because I confirmed the fix locally by running the offending test 100 times - it didn't fail even a single time. Without that change, it fails quite often. |
presence. Other function don't rely on pip anymore.
@armab I initially missed this in #4750 - c919ff9. Now While at it, I also added test cases for other functions in that file - e2ae1a6. I included this change as part of this PR since it's also related to components Python packages and distribution. Sadly it means I will need to port this change to other repos again. |
touch $(VIRTUALENV_COMPONENTS_DIR)/bin/activate | ||
chmod +x $(VIRTUALENV_COMPONENTS_DIR)/bin/activate | ||
|
||
@for component in $(COMPONENTS_WITHOUT_ST2TESTS); do \ |
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.
The only complain that iterating over all services includes st2client, which duplicates .st2client-install-check
that already ran during the make ci-checks
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.
LGTM,
considering all tests pass (Travis is not yet happy).
@armab Correct, but st2client checks are a bit more extensive since we also install dependencies there (aka use So in a sense, tests which run as part of this next task are a subset of the existing st2client tests. |
We run additional ci-checks-nightly as part of a nightly (cron) build.
Per discussion with @Arma, I moved some of the more extensive checks to a nightly (cron) build - e7df5c0. Any additional nightly checks now run as part of the Sadly Travis CI doesn't allow infrastructure as code (aka via travis config) approach to configure nightly builds so I needed to configure it in their WebUI. In the future, we can utilize the same pattern to offload any additional and slower checks to a nightly build (so we speed up master branch merge and PR builds). This doesn't mean we can just offload everything to the nightly build though (as much as possible should run as part of the every PR build). We should still practice diligence and always look for ways to speed up PR and master builds :) |
already runs as part of every master merge build.
Confirmed nightly build is working correctly by "emulating" one (fdf5e96) - https://travis-ci.org/StackStorm/st2/builds/565579951, https://travis-ci.org/StackStorm/st2/jobs/565579954#L3504. |
Follow-up to #4751 where regression was introduced Release automation fix: StackStorm/st2cd#435
FYI this broke the package build for Fixed via StackStorm/st2cd#435 |
This pull request updates all the component Python packages so we include
requirements.txt
files.This is needed to make all the components valid Python packages so they can be re-used outside of the StackStorm/st2 context.
Before that change, only
st2common
andst2client
+ all the runners were valid Python packages.In addition to that, we also need to include
__version__
attribute as part of all the Python package__init__.py
file. This will be handled by StackStorm/st2cd workflow.NOTE: This is similar to the change I made in the past to make action runners valid Python packages.
TODO