Files
nixpkgs/pkgs/development/python-modules/dsmr-parser/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

54 lines
1.1 KiB
Nix

{
lib,
buildPythonPackage,
dlms-cosem,
fetchFromGitHub,
pyserial,
pyserial-asyncio-fast,
pytestCheckHook,
pythonAtLeast,
pytz,
setuptools,
tailer,
}:
buildPythonPackage rec {
pname = "dsmr-parser";
version = "1.4.3";
pyproject = true;
src = fetchFromGitHub {
owner = "ndokter";
repo = "dsmr_parser";
tag = "v${version}";
hash = "sha256-jBrcliN63isFKMqgaFIAPP/ALDdtL/O9mCN8Va+g+NE=";
};
pythonRelaxDeps = [ "dlms_cosem" ];
build-system = [ setuptools ];
dependencies = [
dlms-cosem
pyserial
pyserial-asyncio-fast
pytz
tailer
];
nativeCheckInputs = [ pytestCheckHook ];
disabledTests = lib.optionals (pythonAtLeast "3.12") [ "test_receive_packet" ];
pythonImportsCheck = [ "dsmr_parser" ];
meta = {
description = "Python module to parse Dutch Smart Meter Requirements (DSMR)";
homepage = "https://github.com/ndokter/dsmr_parser";
changelog = "https://github.com/ndokter/dsmr_parser/releases/tag/${src.tag}";
license = with lib.licenses; [ mit ];
maintainers = with lib.maintainers; [ fab ];
mainProgram = "dsmr_console";
};
}