Files
nixpkgs/pkgs/development/python-modules/janus/default.nix
Yueh-Shun Li 76e2a397c2 treewide: pytestFlagsArray -> pytestFlags and join flag and option argument
This treewide change targets Python packages
that specifies pytest flags with pytestFlagsArray,
and whose flags cannot be consructed by other pytestCheckHook-honoured arguments.

Use the __structuredAttrs-agnostic argument pytestFlags
instead of the deprecated pytestFlagsArray.

For flags with option arguments,
join each flag and their option argument into a single command-line argument
following POSIX Utility Argument Syntax[1]
for easier overriding (remove/replace).

Examples:

* [ "-W" "ignore:message:WarningClass" ] ->
  [ "-Wignore:message:WarningClass" ]

* [ "--reruns" "3" ] ->
  [ "--reruns=3" ]

[1]: https://pubs.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap12.html
2025-06-16 01:02:16 +08:00

43 lines
810 B
Nix

{
lib,
buildPythonPackage,
fetchPypi,
pytestCheckHook,
pythonOlder,
pytest-asyncio,
pytest-benchmark,
pytest-cov-stub,
typing-extensions,
}:
buildPythonPackage rec {
pname = "janus";
version = "2.0.0";
format = "setuptools";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-CXDzjg5yVABJbINKNopn7lUdw7WtCiV+Ey9bRvLnd3A=";
};
disabled = pythonOlder "3.6";
propagatedBuildInputs = [ typing-extensions ];
nativeCheckInputs = [
pytest-asyncio
pytest-benchmark
pytest-cov-stub
pytestCheckHook
];
pytestFlags = [ "--benchmark-disable" ];
meta = with lib; {
description = "Mixed sync-async queue";
homepage = "https://github.com/aio-libs/janus";
license = licenses.asl20;
maintainers = [ maintainers.simonchatts ];
};
}