-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Make bootstrap dynamic for travis conditional builds #1594
Conversation
Thanks for it @opacam I like the approach and we can probably merge after some testing. |
Oh yes, uses the system that we use to resolve the dependencies and pick up one bootstrap (just the same as when building without specifying a bootstrap) |
Caused because we try to compile the package with hostpython and we need to use target python or we will not have the right python headers Resolves: kivy#1575
e0dfdc3
to
0563ef0
Compare
ci/constants.py
Outdated
BROKEN_RECIPES_PYTHON2 = set([ | ||
]) | ||
# to be created via https://github.com/kivy/python-for-android/issues/1514 | ||
BROKEN_RECIPES_PYTHON3 = set([ |
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 list is already defined here
python-for-android/ci/constants.py
Line 70 in 0563ef0
BROKEN_RECIPES_PYTHON3 = set([ |
I would keep that comment about #1514 however, good idea
ci/rebuild_updated_recipes.py
Outdated
bootstrap = get_bootstrap(recipes | {target_python.name}) | ||
if bootstrap: | ||
break | ||
else: |
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.
I understand you wanted to keep some meaningful logs to see the fallback in action, but we could greatly simplify the code if we drop that feature actually. Having the trying to get a bootstrap forcing target python
above would be more than enough to guess when falling back. If we do so you can drop all the else
block and the enumerate
requirement
ci/rebuild_updated_recipes.py
Outdated
target_python_priorities[n + 1].name)) | ||
continue | ||
if not bootstrap: | ||
logger.warning('we didn\'t find any valid combination of bootstrap and' |
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.
Minor: this is a good example where I would use double quotes in my string, just to avoid escaping inner single quotes
ci/rebuild_updated_recipes.py
Outdated
logger.warning('we didn\'t find any valid combination of bootstrap and' | ||
' target python...rebuild updated recipes cancelled.' | ||
'The recipes we couldn\'t rebuild are:' | ||
'\n\t-{}'.format('\n\t-'.join(list(recipes)))) |
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.
Minor: why would you need the list()
here, can't you join directly?
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.
Thanks for pushing this further, I left some early comments.
Also I'm puzzled if we want to support both python2
and python2legacy
in that conditional build thing.
I would be tempted to support if it doesn't cause too much trouble, but drop at least one if it starts annoying us
Thanks for the comments, tomorrow I will look into it..:sleeping: |
0563ef0
to
a46564d
Compare
ci/constants.py
Outdated
@@ -96,9 +98,13 @@ class TargetPython(Enum): | |||
'sympy', | |||
'vlc', | |||
]) | |||
# to be created via https://github.com/kivy/python-for-android/issues/XXXX |
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.
I think that we should create an issue page for python2.
What do you think @AndreMiras ?
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.
I don't know if it's worth the effort, but feel free if want
ci/constants.py
Outdated
@@ -5,12 +5,13 @@ class TargetPython(Enum): | |||
python2 = 0 | |||
python3crystax = 1 |
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.
Maybe we should remove python3crystax
?
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.
Yes feel free 👍
ci/rebuild_updated_recipes.py
Outdated
target_python_priorities = [ | ||
TargetPython.python3, | ||
TargetPython.python2, | ||
TargetPython.python2legacy |
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.
python2legacy
is unlikely to be used unless we modify some pygame
dependant recipe, which will be removed soon, so...I'm not sure if we have to introduce this 🤔
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.
Yes by default I would be lazy and drop
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.
Yes, but we already have the work done in here, so maybe we should maintain this, at least until @inclement can finish his pygame removal work
, then maybe we could start to remove all the python2legacy
stuff. It's easy to remove this, I'm more concerned with other python2legacy
code...but we will add some more code to remove...mmm...@inclement, what is your opinion on this?
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.
Ok, after thinking about it, I took the lazy road 😁, removed python2legacy
Again @AndreMiras, so many thanks for your comments of last night, you were right with all of that, and I must say, a lot better 😄. I don't plan touch this pull request unless you request me, so feel free to modify wathever you consider necessary, no problem 😉 (ahhh...and I don't have any more |
Because we don't need that anymore
To make easier to track any issue we got with python3's recipe
a46564d
to
c6d8763
Compare
This should solve: #1588