python312Packages.hf-xet: init at 1.0.3 (#397891)

This commit is contained in:
Gaétan Lepage
2025-04-11 11:10:14 +02:00
committed by GitHub
2 changed files with 60 additions and 0 deletions
@@ -0,0 +1,58 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
pkg-config,
rustPlatform,
openssl,
}:
buildPythonPackage rec {
pname = "hf-xet";
version = "1.0.3";
pyproject = true;
src = fetchFromGitHub {
owner = "huggingface";
repo = "xet-core";
tag = "v${version}";
hash = "sha256-ZbLSPLRsRVSF9HD+R8k/GR7yq3Ej+c+AyYbyHhKOf3w=";
};
sourceRoot = "${src.name}/hf_xet";
cargoDeps = rustPlatform.fetchCargoVendor {
inherit
pname
version
src
sourceRoot
;
hash = "sha256-gO5A457CJUdV7nfy69yliL6uqMu5Fc3rY2uXyMM/Na0=";
};
nativeBuildInputs = [
pkg-config
rustPlatform.cargoSetupHook
rustPlatform.maturinBuildHook
];
buildInputs = [
openssl
];
env.OPENSSL_NO_VENDOR = 1;
pythonImportsCheck = [ "hf_xet" ];
# No tests (yet?)
doCheck = false;
meta = {
description = "Xet client tech, used in huggingface_hub";
homepage = "https://github.com/huggingface/xet-core/hf_xet";
changelog = "https://github.com/huggingface/xet-core/releases/tag/v${version}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ GaetanLepage ];
};
}
+2
View File
@@ -6204,6 +6204,8 @@ self: super: with self; {
hf-transfer = callPackage ../development/python-modules/hf-transfer { };
hf-xet = callPackage ../development/python-modules/hf-xet { };
hfst = callPackage ../development/python-modules/hfst { };
hg-commitsigs = callPackage ../development/python-modules/hg-commitsigs { };