Files
nixpkgs/pkgs/development/python-modules/cfn-lint/default.nix
T
Robert Schütz 1a04744f74 treewide: remove superfluous disabled
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:

    pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
    for f in $(find -name '*.nix'); do
        grep -q "$pattern" "$f" || continue
        sed -i "/$pattern/d" "$f"
        if [ $(grep -c pythonOlder "$f") == 1 ]; then
            sed -i '/^\s*pythonOlder,\s*$/d' "$f"
        fi
        nixfmt "$f"
    done
2026-01-11 09:34:20 -08:00

83 lines
1.5 KiB
Nix

{
lib,
aws-sam-translator,
buildPythonPackage,
defusedxml,
fetchFromGitHub,
jschema-to-python,
jsonpatch,
junit-xml,
mock,
networkx,
pydot,
pytestCheckHook,
pyyaml,
regex,
sarif-om,
setuptools,
sympy,
typing-extensions,
}:
buildPythonPackage rec {
pname = "cfn-lint";
version = "1.41.0";
pyproject = true;
src = fetchFromGitHub {
owner = "aws-cloudformation";
repo = "cfn-lint";
tag = "v${version}";
hash = "sha256-AudCeFMbCQucANLLAknCKC7gzi0vvFh9c9k7ll0a1MM=";
};
build-system = [ setuptools ];
dependencies = [
aws-sam-translator
jsonpatch
networkx
pyyaml
regex
sympy
typing-extensions
];
optional-dependencies = {
graph = [ pydot ];
junit = [ junit-xml ];
sarif = [
jschema-to-python
sarif-om
];
full = lib.concatAttrValues (lib.removeAttrs optional-dependencies [ "full" ]);
};
nativeCheckInputs = [
defusedxml
mock
pytestCheckHook
]
++ optional-dependencies.full;
preCheck = ''
export PATH=$out/bin:$PATH
'';
disabledTests = [
# Requires git directory
"test_update_docs"
];
pythonImportsCheck = [ "cfnlint" ];
meta = {
description = "Checks cloudformation for practices and behaviour that could potentially be improved";
mainProgram = "cfn-lint";
homepage = "https://github.com/aws-cloudformation/cfn-lint";
changelog = "https://github.com/aws-cloudformation/cfn-lint/blob/${src.tag}/CHANGELOG.md";
license = lib.licenses.mit;
maintainers = [ ];
};
}