Skip to content
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

Bootstrap detection for "service_only" and "webview" is broken - always picks sdl2 #1508

Closed
ghost opened this issue Dec 9, 2018 · 3 comments

Comments

@ghost
Copy link

ghost commented Dec 9, 2018

On latest p4a master ( 7f8242f ), the bootstrap detection for "service_only" and "webview" appears to be broken - when using any of those two in the --requirements with no mention of sdl2, p4a will still always pick the sdl2 bootstrap:

Try this yourself e.g. with: --requirements=webview,python2 with https://github.com/kivy/python-for-android/tree/master/testapps/testapp_flask :

...
[INFO]:    Found 4 acceptable bootstraps: ['sdl2', 'webview', 'pygame', 'services_only']
[INFO]:    Using the first of these: sdl2
[INFO]:    Found a single valid recipe set: ['hostpython2', u'webview', u'python2']
[INFO]:    The selected bootstrap is sdl2

--bootstrap's help string claims: "The bootstrap to build with. Leave unset to choose automatically."
So unless I'm missing something obvious, it looks like that is just not what should be happening.

Short-hand test / reproduce command: p4aspaces cmd py4a-py2-api19-ndkbundle "cd ~/testapp-webview-flask && p4a apk --arch=armeabi-v7a --name test --package com.example.test --version 1 --requirements=python2,webview --private ." --p4a master

@ghost
Copy link
Author

ghost commented Dec 9, 2018

I guess I'm not supposed to specify webview in the requirements? Maybe that's the problem. I'm not sure, if someone knows how it's supposed to be built, let me know 😄

@ghost
Copy link
Author

ghost commented Dec 9, 2018

After pondering this some more I don't see how this could even work, since a webview or service_only app has no package to indicate any sort of non-sdl2 dependency, and e.g. flask could also be used in an sdl2-bootstrapped app. There is just no information to derive anything useful from, other than kivy needing the sdl2 bootstrap, which is usually picked as default anyway.

Not sure what to suggest from that info. I guess maybe in the future it could be autodetected, so it's worth leaving it in even if the code does nothing? Or not? I'm not sure

@ghost
Copy link
Author

ghost commented Jan 12, 2019

Closing since this needs some more thought anyway

@ghost ghost closed this as completed Jan 12, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants