2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
stdenv,
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
2024-09-19 14:19:46 +00:00
|
|
|
fetchFromGitHub,
|
2024-06-05 15:53:02 +00:00
|
|
|
glean-parser,
|
|
|
|
pytest-localserver,
|
|
|
|
pytestCheckHook,
|
|
|
|
rustPlatform,
|
|
|
|
semver,
|
2024-09-19 14:19:46 +00:00
|
|
|
setuptools,
|
2021-12-06 16:07:01 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "glean-sdk";
|
2024-09-19 14:19:46 +00:00
|
|
|
version = "60.4.0";
|
|
|
|
pyproject = true;
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mozilla";
|
|
|
|
repo = "glean";
|
|
|
|
rev = "v${version}";
|
|
|
|
hash = "sha256-C3wQdxPNBPQN6eUK6Vq0bA6Wpqb28e9BTBf7c/hTQxU=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
|
|
|
inherit src;
|
|
|
|
name = "${pname}-${version}";
|
2024-09-19 14:19:46 +00:00
|
|
|
hash = "sha256-XqOCHnvM64kZNifU5Wt/bFAvyRVy28ozWSwlvm/sMk8=";
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
build-system = [
|
2021-12-06 16:07:01 +00:00
|
|
|
rustPlatform.cargoSetupHook
|
2024-09-19 14:19:46 +00:00
|
|
|
rustPlatform.maturinBuildHook
|
|
|
|
setuptools
|
2021-12-06 16:07:01 +00:00
|
|
|
];
|
2022-03-30 09:31:56 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
dependencies = [
|
2021-12-06 16:07:01 +00:00
|
|
|
glean-parser
|
2022-09-30 11:47:45 +00:00
|
|
|
semver
|
2021-12-06 16:07:01 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-03-30 09:31:56 +00:00
|
|
|
pytest-localserver
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
pytestFlagsArray = [ "glean-core/python/tests" ];
|
|
|
|
|
2022-08-12 12:06:08 +00:00
|
|
|
disabledTests = [
|
|
|
|
# RuntimeError: No ping received.
|
|
|
|
"test_client_activity_api"
|
2023-05-24 13:37:59 +00:00
|
|
|
"test_flipping_upload_enabled_respects_order_of_events"
|
2024-09-19 14:19:46 +00:00
|
|
|
# A warning causes this test to fail
|
|
|
|
"test_get_language_tag_reports_the_tag_for_the_default_locale"
|
2022-08-12 12:06:08 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "glean" ];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
meta = {
|
2022-06-16 17:23:12 +00:00
|
|
|
broken = stdenv.isDarwin;
|
2022-03-30 09:31:56 +00:00
|
|
|
description = "Telemetry client libraries and are a part of the Glean project";
|
2021-12-06 16:07:01 +00:00
|
|
|
homepage = "https://mozilla.github.io/glean/book/index.html";
|
2024-09-19 14:19:46 +00:00
|
|
|
license = lib.licenses.mpl20;
|
|
|
|
maintainers = with lib.maintainers; [ melling ];
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
}
|