-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Investigate conditional builds #1382
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
Comments
This seems sensible, but I've been fairly quiet about it mostly because I'm not really familiar with how travis works. Are we actually hitting any limits of travis right now, or is this more to avoid problems before they crop up (and for the general convenience of tests not taking too long)? |
This was referenced Oct 3, 2018
AndreMiras
added a commit
that referenced
this issue
Oct 11, 2018
…al_builds Conditional recipe build fixes #1382
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
High level description
Discussed earlier today (at 13:30 UTC) with @tshirtman on discord
#dev
.We would like to investigate how to both increase continuous integration coverage and speed by introducing conditional builds.
Basically the idea would be to build only the recipes updated by a pull request, plus a subset of critical-core recipes.
We could take advantage of both Travis conditional builds, dependency resolver and
git diff --stat master
magic to only build the relevant subset of recipes.This ticket will be used as a brainstorm/spec before implementing the feature.
Things to consider
Conflicting recipes
The result of the stat command may be a list of recipe that conflict with each other.
A simple, but not so efficient way to overcome the issue would be to always build them separately rather than in batch.
So when batch is:
Separately would be:
Don't build twice
Also we should try not building exact thing twice, e.g. we may want to always build some core critical recipes e.g. kivy, python2, etc, but if theses recipes are also updated in the pull request, they will also be built as part of the conditional build. Hence we want to make sure there's no overlap for not wasting time.
Keep it simple and uncoupled
We don't want to have an over-complicated and unmaintainable Travis file. So things should be thought as simple as possible as as reusable as possible.
Sor for example it might be needed to have a dedicated util Bash or Python script for handling some the logic so that the Travis file just has to call it.
Keep building in parallel
Builds currently run in parallel in Travis, currently the maximum jobs that can run in parallel is 5.
If possible we need to make the most of it.
Address different bootstraps
Just like we want to rebuild recipes when they get updated, we also want to batch the updated boostrap (sdl2, pygame, service_only...).
Draft/sandbox
git diff --stats
Use
git diff --stat master
to see what has changed between master and current branch.See example output:
Based on that we can try to list only the recipes that were updated:
The text was updated successfully, but these errors were encountered: