
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
42 lines
884 B
Nix
42 lines
884 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchPypi,
|
|
setuptools,
|
|
pandas,
|
|
pytestCheckHook,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "vega-datasets";
|
|
version = "0.9.0";
|
|
pyproject = true;
|
|
|
|
src = fetchPypi {
|
|
pname = "vega_datasets";
|
|
inherit version;
|
|
hash = "sha256-nb6YNCCOjsMqtElw3zFd6RAoYeTNoT2OFDqreoDZP8A=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
|
|
propagatedBuildInputs = [ pandas ];
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
pytestFlags = [ "--doctest-modules" ];
|
|
|
|
pythonImportsCheck = [ "vega_datasets" ];
|
|
|
|
meta =
|
|
let
|
|
tag = lib.removeSuffix ".0" "v${version}";
|
|
in
|
|
{
|
|
description = "Python package for offline access to vega datasets";
|
|
homepage = "https://github.com/altair-viz/vega_datasets";
|
|
changelog = "https://github.com/altair-viz/vega_datasets/blob/${tag}/CHANGES.md";
|
|
license = lib.licenses.mit;
|
|
};
|
|
}
|