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

[Python] fix build against python 3.8 #17021

Merged
merged 1 commit into from
Dec 13, 2019
Merged

[Python] fix build against python 3.8 #17021

merged 1 commit into from
Dec 13, 2019

Conversation

ronie
Copy link
Member

@ronie ronie commented Dec 10, 2019

Today my Manjaro linux installation updated to python 3.8.0 and i was unable to compile Kodi.

As mentioned in #16560 we are not compatible with the current python version.
This PR implements the workaround as suggested in that issue report.

fixes #16560

@ronie ronie added Type: Fix non-breaking change which fixes an issue Component: Python v19 Matrix labels Dec 10, 2019
@ronie ronie added this to the Matrix 19.0-alpha 1 milestone Dec 10, 2019
Copy link
Member

@jimfcarroll jimfcarroll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like a really bad idea. I remember reviewing the code in PythonInvoker and thinking we need to move away from accessing the internal thread state structures internal to python and I think there were even warnings in the documentation that this could be changed without notice. You can take this for now to get 3.8 working but I'm going to see if there's a compliant way to do the same thing (get access to the chain of thread states).

@ronie
Copy link
Member Author

ronie commented Dec 11, 2019

thanx for the feedback.
i've added it as a todo comment in the code.

# define Py_BUILD_CORE
# undef HAVE_STD_ATOMIC
/* for access to the fields of PyInterpreterState */
# include "internal/pycore_pystate.h"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

include style is wrong, this in not a Kodi header

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanx for the hint, updated.

@ronie ronie merged commit 7c7210d into xbmc:master Dec 13, 2019
Maven85 pushed a commit to Maven85/kodi that referenced this pull request Jan 21, 2020
[Python] fix build against python 3.8
@ronie ronie deleted the py38 branch July 29, 2020 00:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Python Type: Fix non-breaking change which fixes an issue v19 Matrix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feature_python3 - not compatible with Python 3.8
3 participants