Files
nixpkgs/pkgs/development/python-modules/oslo-context/default.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

56 lines
1015 B
Nix

{
lib,
buildPythonPackage,
fetchPypi,
oslotest,
stestr,
pbr,
setuptools,
typing-extensions,
}:
buildPythonPackage rec {
pname = "oslo-context";
version = "6.2.0";
pyproject = true;
src = fetchPypi {
inherit version;
pname = "oslo_context";
hash = "sha256-Rlxn2k2S3Clg3uwUje5GnXrnc2r4aVgeLjtzziz6J6g=";
};
postPatch = ''
# only a small portion of the listed packages are actually needed for running the tests
# so instead of removing them one by one remove everything
rm test-requirements.txt
'';
build-system = [ setuptools ];
dependencies = [
pbr
typing-extensions
];
nativeCheckInputs = [
oslotest
stestr
];
checkPhase = ''
runHook preCheck
stestr run
runHook postCheck
'';
pythonImportsCheck = [ "oslo_context" ];
meta = {
description = "Oslo Context library";
homepage = "https://github.com/openstack/oslo.context";
license = lib.licenses.asl20;
teams = [ lib.teams.openstack ];
};
}