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

Try system python when performing compileall #1109

Merged
merged 2 commits into from Sep 23, 2017

Conversation

inclement
Copy link
Member

@inclement inclement commented Sep 5, 2017

This is kind of messy, but there doesn't seem to be a very neat way to do it.

The point of doing this is that the compileall can fail for some files if it tries to load .so files (which hostpython doesn't have available). In particular, this occurs for files which try to access unicode characters with '\N{...}'. For instance, several files in sympy do this, and currently crash when sympy is imported on the device. This PR would make the compilation work in such cases.

For now, I think discussion would be better than straight merging, but having the change documented could help someone.

@inclement inclement added this to the 0.6 milestone Sep 5, 2017
@inclement inclement changed the title Try system python compile Try system python when performing compileall Sep 5, 2017
@inclement
Copy link
Member Author

inclement commented Sep 5, 2017

I suppose another thing we could do is detect files for which compilation has failed, and automatically whitelist their .py versions (these should work okay when actually on the device). This might be a good general solution, along with also flagging this problem to the user.

@inclement inclement merged commit 922625c into kivy:master Sep 23, 2017
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

Successfully merging this pull request may close these issues.

None yet

1 participant