lol

python312Packages.tokenizers: 0.21.0 -> 0.21.1 (#389517)

authored by

Nick Cao and committed by
GitHub
fd5a4d4b a091446c

+18 -11
+18 -11
pkgs/development/python-modules/tokenizers/default.nix
··· 24 24 pytestCheckHook, 25 25 requests, 26 26 tiktoken, 27 + writableTmpDirAsHomeHook, 27 28 }: 28 29 29 30 let ··· 70 71 in 71 72 buildPythonPackage rec { 72 73 pname = "tokenizers"; 73 - version = "0.21.0"; 74 + version = "0.21.1"; 74 75 pyproject = true; 75 76 76 77 src = fetchFromGitHub { 77 78 owner = "huggingface"; 78 79 repo = "tokenizers"; 79 80 tag = "v${version}"; 80 - hash = "sha256-G65XiVlvJXOC9zqcVr9vWamUnpC0aa4kyYkE2v1K2iY="; 81 + hash = "sha256-3S7ZCaZnnwyNjoZ4Y/q3ngQE2MIm2iyCCjYAkdMVG2A="; 81 82 }; 82 83 84 + # TestUnigram.test_continuing_prefix_trainer_mismatch fails with: 85 + # Exception: No such file or directory (os error 2) 86 + # Fix submitted upstream: https://github.com/huggingface/tokenizers/pull/1747 87 + postPatch = '' 88 + substituteInPlace tests/bindings/test_trainers.py \ 89 + --replace-fail '"data/' '"tests/data/' 90 + ''; 91 + 83 92 cargoDeps = rustPlatform.fetchCargoVendor { 84 93 inherit 85 94 pname ··· 87 96 src 88 97 sourceRoot 89 98 ; 90 - hash = "sha256-jj5nuwxlfJm1ugYd5zW+wjyczOZHWCmRGYpmiMDqFlk="; 99 + hash = "sha256-I7LlBmeVY2rWI0ta6x311iAurQKuutsClrbUgkt9xWk="; 91 100 }; 92 101 93 102 sourceRoot = "${src.name}/bindings/python"; ··· 115 124 pytestCheckHook 116 125 requests 117 126 tiktoken 127 + writableTmpDirAsHomeHook 118 128 ]; 119 129 120 - postUnpack = '' 130 + postUnpack = 121 131 # Add data files for tests, otherwise tests attempt network access 122 - mkdir $sourceRoot/tests/data 123 - ln -s ${test-data}/* $sourceRoot/tests/data/ 124 - ''; 125 - 126 - preCheck = '' 127 - export HOME=$(mktemp -d); 128 - ''; 132 + '' 133 + mkdir $sourceRoot/tests/data 134 + ln -s ${test-data}/* $sourceRoot/tests/data/ 135 + ''; 129 136 130 137 pythonImportsCheck = [ "tokenizers" ]; 131 138