nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at haskell-updates 58 lines 1.4 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 pythonAtLeast, 5 6 # build-system 7 setuptools, 8 9 # dependencies 10 hydra-core, 11 joblib, 12 13 # test 14 pytestCheckHook, 15}: 16 17buildPythonPackage (finalAttrs: { 18 pname = "hydra-joblib-launcher"; 19 pyproject = true; 20 21 inherit (hydra-core) version src; 22 23 # _pickle.PicklingError: Could not pickle the task to send it to the workers 24 disabled = pythonAtLeast "3.14"; 25 26 sourceRoot = "${finalAttrs.src.name}/plugins/hydra_joblib_launcher"; 27 28 # get rid of deprecated "read_version" dependency, no longer in Nixpkgs: 29 postPatch = '' 30 substituteInPlace pyproject.toml --replace-fail ', "read-version"' "" 31 substituteInPlace setup.py \ 32 --replace-fail 'from read_version import read_version' "" \ 33 --replace-fail 'version=read_version("hydra_plugins/hydra_joblib_launcher", "__init__.py"),' 'version="${finalAttrs.version}",' 34 ''; 35 36 build-system = [ 37 setuptools 38 ]; 39 40 dependencies = [ 41 hydra-core 42 joblib 43 ]; 44 45 nativeCheckInputs = [ 46 pytestCheckHook 47 ]; 48 49 # tries to write to source directory otherwise: 50 pytestFlagsArray = [ "-p no:cacheprovider" ]; 51 52 meta = { 53 inherit (hydra-core.meta) changelog license; 54 description = "Hydra launcher supporting parallel execution based on Joblib.Parallel"; 55 homepage = "https://hydra.cc/docs/plugins/joblib_launcher"; 56 maintainers = with lib.maintainers; [ bcdarwin ]; 57 }; 58})