Program freezes when playing any move on 1.17.1
I'm experiencing a bug that appears to be the same as issues #752 and #768, but I'm encountering it on version 1.17.1.
The root cause may be related to either Kivy (possibly https://github.com/kivy/kivy/issues/9023) or Python.
I found a couple of workarounds:
pip install kivy==2.3.0with git cloned Katrain- Making the play_sound() function in katrain/gui/sound.py blank
KaTrain version: v1.17.1
Installation method: pipx install katrain
Python version: 3.12.3
OS: Ubuntu 24.04
Thanks!
It's also the same as https://github.com/sanderland/katrain/issues/691
Edit:
Okay after some more testing it seems kivy's bundled sdl2 libraries are also fixed on my distros python-kivy:2.3.1-1, so i just opted to using my system packages with below.
Steps:
sudo pacman -S python-kivy sdl2_ttf sdl2_image sdl2_mixer gstreamer
# venv
python3 -m venv --system-site-packages ~/katrain-env
source ~/katrain-env/bin/activate
pip install -U katrain
katrain
Installing with venv doesnt add the app to the path though, so i just made a tiny bash script and a desktop file for launching said script.
Katrain 1.17.1 Install methond: venv/pip Python: 3.13.5 OS: Manjaro Linux, KDE Plasma 6.4.1 (Wayland)
@ojsl1 's workaround unfortunately didn't work for me on Arch Linux, but I found a much easier one than patching out the play_sound() function--go to General & Engine settings and uncheck "Sound On". Seems to work fine obviously other than the lack of audio.
For completeness sake this was the old method that fixed the sound and resizing for me (i just tested and it still does):
python -m venv katrain
source katrain/bin/activate
pip install --no-binary=kivy katrain
python -m katrain
@njfox Thank you for your easy solution. I can confirm that by going to General & Engine settings and uncheck "Sound On" solves the problem. Just don't forget to hit "Update Settings".
I also encountered this bug on my Linux Mint machine. I have a dual boot Windows 11 system on this same machine on another SSD drive, and the exe file works just fine. This bug seems Linux specific when I had to install katrain myself.
My Linux Mint katrain installation process uses standard virtual Python enviroment
#shell
python3 -m venv venv
. venv/bin/activate
#venv
pip3 install -U katrain
katrain
I was able to use the GUI, open SGF files, and make analysis using graphic card by using mouse scroll to cycle through moves. But as soon as I played any stone on the board, the app freezed.
KaTrain version: v1.17.1 Python version: 3.12.3 OS: Linux Mint 22.2 Cinnamon
I can confirm the same behaviour on Fedora Linux - the app was seemingly working but was freezing when playing a stone. I experienced it back in June with 1.17 version.
I spent some time on it, trying to troubleshoot and fix it myself but at the end I gave up and just downgraded to v1.16, then it worked fine.
Debian Bookworm or Trixie the same to yours. The Sound Off Method works.