Skip to content

Commit

Permalink
python312Packages.pysmi: 0.3.4 -> 1.4.4
Browse files Browse the repository at this point in the history
https://github.com/lextudio/pysmi/blob/v1.4.4/CHANGES.rst

Absorbs pysmi-lextudio, since the author of pysmi has passed away and
the lextudio fork has now become pysmi.
  • Loading branch information
mweinelt committed Sep 1, 2024
1 parent 358d937 commit ee09228
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 62 deletions.
46 changes: 0 additions & 46 deletions pkgs/development/python-modules/pysmi-lextudio/default.nix

This file was deleted.

54 changes: 42 additions & 12 deletions pkgs/development/python-modules/pysmi/default.nix
Original file line number Diff line number Diff line change
@@ -1,29 +1,59 @@
{
lib,
buildPythonPackage,
fetchPypi,
fetchFromGitHub,

# build-system
poetry-core,

# dependencies
ply,
jinja2,
requests,

# tests
pysnmp,
pytestCheckHook,
}:

buildPythonPackage rec {
version = "0.3.4";
format = "setuptools";
let self = buildPythonPackage rec {
version = "1.4.4";
pname = "pysmi";
pyproject = true;

src = fetchPypi {
inherit pname version;
sha256 = "bd15a15020aee8376cab5be264c26330824a8b8164ed0195bd402dd59e4e8f7c";
src = fetchFromGitHub {
owner = "lextudio";
repo = "pysmi";
rev = "refs/tags/v${version}";
hash = "sha256-9ArKo1UT4g+H8Z51NZ6rHlOhyz2grAc1V8Xl+ztfYic=";
};

propagatedBuildInputs = [ ply ];
build-system = [ poetry-core ];

dependencies = [
ply
jinja2
requests
];

# Tests require pysnmp, which in turn requires pysmi => infinite recursion
doCheck = false;

nativeCheckInputs = [
pysnmp
pytestCheckHook
];

pythonImportsCheck = [ "pysmi" ];

passthru.tests.pytest = self.overridePythonAttrs { doCheck = true; };

meta = with lib; {
homepage = "http://pysmi.sf.net";
description = "SNMP SMI/MIB Parser";
description = "SNMP MIB parser";
homepage = "https://github.com/lextudio/pysmi";
changelog = "https://github.com/lextudio/pysmi/blob/v${version}/CHANGES.rst";
license = licenses.bsd2;
maintainers = with maintainers; [ koral ];
maintainers = with maintainers; [ fab ];
};
}
};
in self
4 changes: 2 additions & 2 deletions pkgs/development/python-modules/pysnmp-lextudio/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

# dependencies
pyasn1,
pysmi-lextudio,
pysmi,
pysnmpcrypto,

# tests
Expand All @@ -32,7 +32,7 @@ buildPythonPackage rec {

propagatedBuildInputs = [
pyasn1
pysmi-lextudio
pysmi
pysnmpcrypto
];

Expand Down
1 change: 1 addition & 0 deletions pkgs/top-level/python-aliases.nix
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,7 @@ mapAliases ({
pysha3 = throw "pysha3 has been removed, use safe-pysha3 instead"; # added 2023-05-20
pysmart-smartx = pysmart; # added 2021-10-22
pySmartDL = pysmartdl; # added 2023-10-11
pysmi-lextudio = pysmi; # added 2024-07-18
pysparse = throw "pysparse has been abandoned upstream."; # added 2023-02-28
pyspotify = throw "pyspotify has been removed because Spotify stopped supporting libspotify"; # added 2022-05-29
PyStemmer = pystemmer; # added 2023-02-19
Expand Down
2 changes: 0 additions & 2 deletions pkgs/top-level/python-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12423,8 +12423,6 @@ self: super: with self; {

pysmi = callPackage ../development/python-modules/pysmi { };

pysmi-lextudio = callPackage ../development/python-modules/pysmi-lextudio { };

pysml = callPackage ../development/python-modules/pysml { };

pysmlight = callPackage ../development/python-modules/pysmlight { };
Expand Down

0 comments on commit ee09228

Please sign in to comment.