python312Packages.swh-export: init at 1.8.0

This commit is contained in:
Pol Dellaiera
2025-04-02 23:22:33 +02:00
parent f280136abd
commit fcd2e4bdaf
3 changed files with 93 additions and 0 deletions
+1
View File
@@ -3,6 +3,7 @@
writeShellApplication,
withSwhPythonPackages ? [
python3Packages.swh-auth
python3Packages.swh-export
python3Packages.swh-model
python3Packages.swh-objstorage
python3Packages.swh-scanner
@@ -0,0 +1,90 @@
{
lib,
buildPythonPackage,
fetchFromGitLab,
setuptools,
setuptools-scm,
boto3,
click,
tqdm,
pyorc,
plyvel,
python,
types-requests,
swh-core,
swh-journal,
swh-model,
swh-storage,
pytestCheckHook,
pytest-kafka,
pytest-mock,
tzdata,
pkgs,
}:
buildPythonPackage rec {
pname = "swh-export";
version = "1.8.0";
pyproject = true;
src = fetchFromGitLab {
domain = "gitlab.softwareheritage.org";
group = "swh";
owner = "devel";
repo = "swh-export";
tag = "v${version}";
hash = "sha256-n97MMYn7EmTrv411YSxUD1+zfbFB8KOSns44N3NqqV8=";
};
build-system = [
setuptools
setuptools-scm
];
dependencies = [
boto3
click
tqdm
pyorc
plyvel
types-requests
swh-core
swh-journal
swh-model
swh-storage
];
preCheck = ''
# provide timezone data, works only on linux
export TZDIR=${tzdata}/${python.sitePackages}/tzdata/zoneinfo
'';
pythonImportsCheck = [ "swh.export" ];
nativeCheckInputs = [
pytestCheckHook
pytest-kafka
pytest-mock
pkgs.zstd
pkgs.pv
];
disabledTests = [
# I don't know how to fix the following error
# E fixture 'kafka_server' not found
"test_parallel_journal_processor"
"test_parallel_journal_processor_origin"
"test_parallel_journal_processor_origin_visit_status"
"test_parallel_journal_processor_offsets"
"test_parallel_journal_processor_masked"
"test_parallel_journal_processor_masked_origin"
"test_parallel_journal_processor_masked_origin_visit_statuses"
];
meta = {
description = "Software Heritage dataset tools";
homepage = "https://gitlab.softwareheritage.org/swh/devel/swh-export";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [ drupol ];
};
}
+2
View File
@@ -16673,6 +16673,8 @@ self: super: with self; {
swh-core = callPackage ../development/python-modules/swh-core { };
swh-export = callPackage ../development/python-modules/swh-export { };
swh-journal = callPackage ../development/python-modules/swh-journal { };
swh-model = callPackage ../development/python-modules/swh-model { };