LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-05-2022, 02:58 PM   #1
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Rep: Reputation: Disabled
Question Slackware 15.0 and KODI crashing


Greetings.

I have KODI Matrix compiled and running on a few Slackware64 15.0 machines. It's not very stable though and segfaults frequently while trying to do simple things like exiting a menu or getting a list of files to play. The issue seems to be Python 3.9, as if I uninstall 3.9, install the python3-3.8.6-x86_64-2.txz package, and then recompile KODI, it is then very stable. I use my own script to compile, but I've also tried compiling KODI using the SlackBuild file, and installing KODI via Flatpak, but the same instability occurs with Python 3.9. So I was wondering two things.

1) Is there a way to get a list of all packages that are dependant on Python 3.9, so that I can uninstall and recompile them to use Python 3.8?

-OR-

2) Am I able to compile and install Python 3.8 under say /usr/local and then tell KODI to use that when building? (I can't seem to find an option in the KODI build process to do so.)

Thanks in advance.
 
Old 04-05-2022, 05:26 PM   #2
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by Barcoboy View Post
1) Is there a way to get a list of all packages that are dependant on Python 3.9, so that I can uninstall and recompile them to use Python 3.8?
This should get most, if not all that are compiled against python3.9.

Code:
grep python3\\.9 /var/lib/pkgtools/packages/ | cut -d/ -f5 | cut -d: -f1 | uniq
Quote:
Originally Posted by Barcoboy View Post
2) Am I able to compile and install Python 3.8 under say /usr/local and then tell KODI to use that when building? (I can't seem to find an option in the KODI build process to do so.)
It looks like there is this cmake option:

Code:
-DPYTHON_VERSION=${PYTHON_VERSION}
It might just try and use a python${PYTHON_VERSION} binary within the $PATH.

Out of curiosity, have you found any consistent way to make kodi crash? I am the one who updated the SBo SlackBuild to build 19.4 and I didn't see any crashes when I was testing it after building, but I haven't migrated my htpc to 15.0 yet to run it full-time. I'd be interested in trying to track down the culprit and see if we can get a fix integrated into the SlackBuild.
 
Old 04-05-2022, 07:54 PM   #3
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
It looks like there is this cmake option:

Code:
-DPYTHON_VERSION=${PYTHON_VERSION}
It might just try and use a python${PYTHON_VERSION} binary within the $PATH.
Thanks for your post bassmadrigal. I've made some advancements. After running cmake to configure, I went back to my build directory and typed "cmake -LA", and I found these three build options which are related to Python:

Code:
PYTHON_EXECUTABLE:FILEPATH=/usr/bin/python3
PYTHON_INCLUDE_DIR:PATH=/usr/include/python3.9
PYTHON_LIBRARY:FILEPATH=/usr/lib64/libpython3.9.so
So I've renamed my python3 package to python38-3.8.6-x86_64-2.txz, and was able to install it along with the standard 15.0 python3-3.9 package. I then modified my build script to include:

Code:
-DPYTHON_EXECUTABLE:FILEPATH=/usr/bin/python38
-DPYTHON_INCLUDE_DIR:PATH=/usr/include/python3.8
-DPYTHON_LIBRARY:FILEPATH=/usr/lib64/libpython3.8.so
Trying a build now... we'll see how it works.

Quote:
Originally Posted by bassmadrigal View Post

Out of curiosity, have you found any consistent way to make kodi crash? I am the one who updated the SBo SlackBuild to build 19.4 and I didn't see any crashes when I was testing it after building, but I haven't migrated my htpc to 15.0 yet to run it full-time. I'd be interested in trying to track down the culprit and see if we can get a fix integrated into the SlackBuild.
I don't think it is the SlackBuild's fault or KODI itself. Things are fairly stable when KODI is first installed, but the problems start once addons get installed. The worst one for me is the YouTube addon. I can install it, run the initial configuration, import my API key, and then login. But once I've done all that, if I start KODI, start the YouTube addon, and then immediately go back to the main menu, KODI segfaults every time. I've seen other people having the same sort of problems, and everybody says steering away from Python 3.9 and going back solves their issues. The skin "Amber" that I use also seems to make things less stable.
 
Old 04-05-2022, 09:38 PM   #4
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by Barcoboy View Post
I don't think it is the SlackBuild's fault or KODI itself. Things are fairly stable when KODI is first installed, but the problems start once addons get installed. The worst one for me is the YouTube addon. I can install it, run the initial configuration, import my API key, and then login. But once I've done all that, if I start KODI, start the YouTube addon, and then immediately go back to the main menu, KODI segfaults every time. I've seen other people having the same sort of problems, and everybody says steering away from Python 3.9 and going back solves their issues. The skin "Amber" that I use also seems to make things less stable.
I don't know what happened... I reinstalling kodi and dependencies (after realizing I screwed up the REQUIRES line by including the optional shairplay and leaving out platform -- gotta send in a fix for that) and installed the YouTube addon.

Like you, I got crashes when exiting the addon. I then tried installing inputstream.adaptive and its dependency and still had a crash. I then went in and enabled debugging in the settings to hopefully get more from the log (because I have no idea what to do with the backtrace included with the crashlog and the non-debug log wasn't helpful) and now I can't get it to crash again. It seems to be stable and solid when using the YouTube addon and exiting back to the main kodi screen.

Weird!

Do you happen to have links for the other bug reports with this? I'd be interested to see if any of them led to a patch that I could apply to prevent it from happening in the first place.
 
Old 04-05-2022, 09:56 PM   #5
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
I don't know what happened... I reinstalling kodi and dependencies (after realizing I screwed up the REQUIRES line by including the optional shairplay and leaving out platform -- gotta send in a fix for that) and installed the YouTube addon.

Like you, I got crashes when exiting the addon. I then tried installing inputstream.adaptive and its dependency and still had a crash. I then went in and enabled debugging in the settings to hopefully get more from the log (because I have no idea what to do with the backtrace included with the crashlog and the non-debug log wasn't helpful) and now I can't get it to crash again. It seems to be stable and solid when using the YouTube addon and exiting back to the main kodi screen.

Weird!
Yeah, sometimes that would happen for me too, but it would eventually crash again. Two other places KODI would crash in the YouTube addon are sometimes after a video had finished playing (it seemed the longer the video was, the more apt it was to crash), and right after submitting a new search or removing an existing search.

Quote:
Originally Posted by bassmadrigal View Post
Do you happen to have links for the other bug reports with this? I'd be interested to see if any of them led to a patch that I could apply to prevent it from happening in the first place.
And naturally I cannot find any of the previous pages I had found in the past! Grrrr...

The good news is that the new build options seem to be working... KODI is back to being stable on one machine I tested it on. Will try the same thing on my other machines and do more thorough testing tomorrow.
 
Old 04-06-2022, 01:31 AM   #6
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Shoot, well, I have been able to consistently get it to crash with using the search and trying to remove that search entry. I also found it crashed after playing a Netflix show, so it doesn't seem to be related to just the YouTube addon.

I'll be playing around with this some more tomorrow (it's getting late) and see if I can get a bug report submitted to the kodi devs (which from reading a few other reports, sounds like it might actually be a cpython issue). I might have to try a nightly build to see if it's occurring with the eventual v20. I don't think it'd be good to include python3.8 with the kodi package on SBo, so we'll need to figure out a way forward.
 
Old 04-07-2022, 12:36 PM   #7
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Original Poster
Rep: Reputation: Disabled
Glad that you were able to reproduce it consistently, and hopefully the devs will be able to solve it. In the meantime, my further testing with both Python 3.8 for KODI and 3.9 installed for everything else has gone well, with only one crash when exiting the YouTube addon back to the main menu. A while back I did try building Nexus but had the same instability-not sure if it would be any better now.

Wondering if anybody would have the SlackBuild source files for the 3.8 build? I was able to get the last packaged version of 3.8 from the Slackware UK Cumulative archive, but all of my Google and archive.org searches for the 3.8 source files have turned up empty. I tried using the 3.9 SlackBuild, but there are patches that fail to apply with the 3.8 code. Would like to upgrade my 3.8.6 package to 3.8.13.
 
Old 04-07-2022, 04:57 PM   #8
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by Barcoboy View Post
Glad that you were able to reproduce it consistently, and hopefully the devs will be able to solve it. In the meantime, my further testing with both Python 3.8 for KODI and 3.9 installed for everything else has gone well, with only one crash when exiting the YouTube addon back to the main menu. A while back I did try building Nexus but had the same instability-not sure if it would be any better now.
I ended up having a big event for work come up this week into the weekend, so I might not be able to track the bug down this weekend.

Quote:
Originally Posted by Barcoboy View Post
Wondering if anybody would have the SlackBuild source files for the 3.8 build? I was able to get the last packaged version of 3.8 from the Slackware UK Cumulative archive, but all of my Google and archive.org searches for the 3.8 source files have turned up empty. I tried using the 3.9 SlackBuild, but there are patches that fail to apply with the 3.8 code. Would like to upgrade my 3.8.6 package to 3.8.13.
https://git.slackware.nl/current would have what you're looking for, but you'd need to go back through the history of the python3 SlackBuild to find when it was building 3.8 (if it was even modified... it might have the exact same build options as 3.9).
 
Old 04-07-2022, 09:24 PM   #9
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
https://git.slackware.nl/current would have what you're looking for, but you'd need to go back through the history of the python3 SlackBuild to find when it was building 3.8 (if it was even modified... it might have the exact same build options as 3.9).
Many thanks for that. I was able to build a 3.8.13 package, and everything continues to work fine.

Keep me posted about your bug tracking.
 
Old 06-21-2022, 01:02 PM   #10
alias11
LQ Newbie
 
Registered: Jun 2022
Location: Preußen
Distribution: Artix,Slackware,Void,MX,FreeBSD,Devuan
Posts: 3

Rep: Reputation: 0
Quote:
Originally Posted by Barcoboy View Post
Many thanks for that. I was able to build a 3.8.13 package, and everything continues to work fine.

Keep me posted about your bug tracking.
Can you help me out ? Please share the Files or Links, Slackbuilds etc. I need a working Kodi on my Slackware 15 Install. Thx.
 
Old 06-22-2022, 01:21 AM   #11
fourtysixandtwo
Member
 
Registered: Jun 2021
Location: Alberta
Distribution: Slackware...mostly
Posts: 314

Rep: Reputation: 209Reputation: 209Reputation: 209
Quote:
Originally Posted by Barcoboy View Post
Many thanks for that. I was able to build a 3.8.13 package, and everything continues to work fine.

Keep me posted about your bug tracking.
I haven't used it in a while on my desktop (use LibreElec on an rpi normally) but trying it now, it does indeed crash.

Have you tried python 3.9.13? I found this comment https://github.com/xbmc/xbmc/issues/...ent-1153126673 that implies it fixes the issue and is something the LibreElec devs found.

Compiled and installed the python3 source for 3.9.13 from -current and I haven't been able to get it to crash yet.
 
Old 06-22-2022, 07:47 AM   #12
alias11
LQ Newbie
 
Registered: Jun 2022
Location: Preußen
Distribution: Artix,Slackware,Void,MX,FreeBSD,Devuan
Posts: 3

Rep: Reputation: 0
Quote:
Originally Posted by fourtysixandtwo View Post
I haven't used it in a while on my desktop (use LibreElec on an rpi normally) but trying it now, it does indeed crash.

Have you tried python 3.9.13? I found this comment https://github.com/xbmc/xbmc/issues/...ent-1153126673 that implies it fixes the issue and is something the LibreElec devs found.

Compiled and installed the python3 source for 3.9.13 from -current and I haven't been able to get it to crash yet.
I would like to try, but i dont know whre i have to look. https://git.slackware.nl/current i dont know how to handle that site.
Please link me to the slackbuild and the source. Thanks and sorry.
 
Old 06-22-2022, 03:19 PM   #13
fourtysixandtwo
Member
 
Registered: Jun 2021
Location: Alberta
Distribution: Slackware...mostly
Posts: 314

Rep: Reputation: 209Reputation: 209Reputation: 209
Quote:
Originally Posted by alias11 View Post
I would like to try, but i dont know whre i have to look. https://git.slackware.nl/current i dont know how to handle that site.
Please link me to the slackbuild and the source. Thanks and sorry.
Here's an easy method.

Code:
mkdir python3
cd python3
lftp -c "mirror https://mirrors.kernel.org/slackware/slackware64-current/source/d/python3 ."
#make sure the version is still the one we want (3.9.13)

#as root
cd /path_used_above/python3
sh ./python3.SlackBuild

#if the build is successful
upgradepkg /tmp/python3-3.9.13-x86_64-1.txz

Last edited by fourtysixandtwo; 06-22-2022 at 03:21 PM.
 
Old 06-22-2022, 03:40 PM   #14
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
I'll have to check if that newer python fixes it on my system. I tried installing a python3.8 next to the system python3.9 and I went down a rabbit hole of missing dependencies from python that I needed to force a python3.8 build within the SlackBuild scripts (and keep the existing python3.9 to not break system apps) and then upgrade those packages. I lost my patience after like 10 or 15 packages and still having build failures of kodi.
 
Old 06-22-2022, 03:51 PM   #15
Barcoboy
Member
 
Registered: May 2010
Distribution: Slackware
Posts: 54

Original Poster
Rep: Reputation: Disabled
I can confirm that Python3 3.9.13 does seem to fix the crashing problems I was having.

fourtysixandtwo beat me to it. I was going to post a tutorial on how to do the upgrade after I had done some testing, but my power went out for a couple of hours today so I didn't get time to finish until now. I think though that the lftp "mirror" command will create the subdirectory locally when transferring files, so you may end up with python3/python3. Not a big deal though.

I'm guessing this or a future version of 3.9 will appear in Slack 15.0 eventually once a security patch becomes necessary, as 3.9.10 was the original version released with 15.0, and the patches directory currently contains 3.9.12.
 
  


Reply

Tags
compile, kodi, python3, slackware 15.0



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] KODI Krypton - 17.x MediaPlayer - Optimized for Raspberry Pi1/Pi2/Pi3 on Slackware ARM 14.2 SF & Slackware ARM - current HF abga Slackware - ARM 40 08-28-2018 08:50 PM
LXer: Kodi Devs Celebrate New Year with First Release Candidate of Kodi 17 "Krypton" LXer Syndicated Linux News 0 01-01-2017 12:00 AM
[SOLVED] Kodi freezes on exit, kodi.bin won't die pressman57 Linux - Software 6 12-19-2016 07:48 PM
Many complications after crashing first install and crashing and reinstalling several dong Linux - Newbie 1 10-06-2008 04:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration