From 29f2db4b68dc5c0cf06964e8c9b65e7ffa5e0c84 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Giraudeau Date: Fri, 20 Dec 2024 10:31:26 +0100 Subject: [PATCH] python312Packages.trainer: 0.0.36 -> 0.2.0 and switch to idiap fork to unbreak build: original coqui-ai repo is not maintained anymore. https://www.idiap.ch/en/ --- .../python-modules/trainer/default.nix | 24 +++++++------------ 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/pkgs/development/python-modules/trainer/default.nix b/pkgs/development/python-modules/trainer/default.nix index 117e954e7f308d..bf178b011c52b3 100644 --- a/pkgs/development/python-modules/trainer/default.nix +++ b/pkgs/development/python-modules/trainer/default.nix @@ -4,6 +4,8 @@ fetchFromGitHub, fetchpatch, + hatchling, + coqpit, fsspec, torch, @@ -17,32 +19,24 @@ }: let - pname = "trainer"; - version = "0.0.36"; + pname = "coqui-tts-trainer"; + version = "0.2.0"; in buildPythonPackage { inherit pname version; format = "pyproject"; src = fetchFromGitHub { - owner = "coqui-ai"; - repo = "Trainer"; + owner = "idiap"; + repo = "coqui-ai-Trainer"; rev = "refs/tags/v${version}"; - hash = "sha256-z6TOzWqE3NytkdG3nUzh9GpFVGQEXFyzSQ8gvdB4wiw="; + hash = "sha256-zm8BTfXvfwuWpmHFcSxuu+/V4bKanSBU2dniQboVdLY="; }; - patches = [ - (fetchpatch { - name = "add-support-for-python312.patch"; - hash = "sha256-V5RPn/2pGKzQrf/SIRU3imo6nBhpBEJpI7HsFYbVZj4="; - url = "https://github.com/coqui-ai/Trainer/commit/0278012c7e6f5972b656d11757add4ab89f6d272.patch"; - }) + nativeBuildInputs = [ + hatchling ]; - postPatch = '' - sed -i 's/^protobuf.*/protobuf/' requirements.txt - ''; - propagatedBuildInputs = [ coqpit fsspec