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

katrain freezes when making a play #691

Closed
sagehane opened this issue Jun 20, 2024 · 3 comments
Closed

katrain freezes when making a play #691

sagehane opened this issue Jun 20, 2024 · 3 comments
Labels

Comments

@sagehane
Copy link

sagehane commented Jun 20, 2024

Setup

$ nix-info -m
 - system: `"x86_64-linux"`
 - host os: `Linux 6.6.31, NixOS, 24.11 (Vicuna), 24.11.20240618.c00d587`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.2`
 - channels(root): `"nixos"`
 - nixpkgs: `/nix/store/pfqbxdicyksnqda6h5xv285sx7vamwzd-source

On NixOS Unstable with katrain built from the following source:

{ python3Packages }:
with python3Packages;

let
  ffpyplayer = buildPythonPackage rec {
    pname = "ffpyplayer";
    version = "4.5.1";

    src = fetchPypi {
      inherit pname;
      inherit version;
      hash = "sha256-1V1UVj/PbDNFBbRdS2SCXyT6+1rPp6nkcsCOh39UkGk=";
    };

    nativeBuildInputs = with pkgs; [
      cython_0
      pkg-config
      pytest

    ];

    buildInputs = with pkgs; [
      SDL2
      ffmpeg-headless
    ];
  };

  # https://github.com/sanderland/katrain/issues/445
  kivymd = buildPythonPackage rec {
    pname = "kivymd";
    version = "0.104.1";

    src = fetchPypi {
      inherit pname;
      inherit version;
      hash = "sha256-ncvCy4r/3pyCVyGY/dsyyBTN1XJUoOSwDFOILbLI1qY=";
    };

    nativeBuildInputs = [
      #docutils
    ];

    propagatedBuildInputs = [ kivy ];

    doCheck = false;
  };
in
buildPythonPackage rec {
  pname = "KaTrain";
  version = "1.14.0";

  src = fetchPypi {
    inherit pname;
    inherit version;
    hash = "sha256-gMZ8b3oB/WReaK6aN7yLU+ZegGHi/sJpgvshXuxqcf4=";
  };

  nativeBuildInputs = [
    #docutils
  ];

  # Seems to be an optional runtime dependency
  buildInputs = [
    # wl-clipboard-x11

    # xclip
    # xsel
  ];

  # https://github.com/sanderland/katrain/blob/v1.14.0/setup.py
  propagatedBuildInputs = [
    chardet
    screeninfo
    setuptools
    urllib3

    ffpyplayer
    kivymd
  ];

  doCheck = false;
}

I use a wlroots-based Wayland window manager called River, with XWayland enabled.

Current Behaviour

The program consistently freezes immediately after making a play, with no error messages.
It becomes completely unresponsive and uses a lot of CPU resources.

strace reveals that the following futex calls are being spammed after the freeze:

futex(0x7f2d137bf310, FUTEX_WAIT_BITSET_PRIVATE, 0, {tv_sec=6134, tv_nsec=405410057}, FUTEX_BITSET_MATCH_ANY) = -1 ETIMEDOUT (Connection timed out)
futex(0x7f2d137bf318, FUTEX_WAKE_PRIVATE, 1) = 0
@sagehane
Copy link
Author

I'm also getting a crash with an expression generated by https://github.com/nix-community/pip2nix, so I'm suspecting it might be an issue with window manager setup or similar...

Copy link

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 10 days.

@github-actions github-actions bot added the Stale label Sep 19, 2024
Copy link

This issue was closed because it has been stalled for 30 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Oct 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant