Skip to content

Commit c6706b5

Browse files
committed
1 parent d97c135 commit c6706b5

File tree

1 file changed

+14
-9
lines changed
  • pkgs/development/python-modules/python-mimeparse

1 file changed

+14
-9
lines changed

pkgs/development/python-modules/python-mimeparse/default.nix

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,34 @@
11
{
22
lib,
33
buildPythonPackage,
4-
fetchPypi,
5-
legacy-cgi,
4+
fetchFromGitHub,
65
pytestCheckHook,
7-
pythonAtLeast,
6+
pythonOlder,
7+
setuptools,
88
}:
99

1010
buildPythonPackage rec {
1111
pname = "python-mimeparse";
12-
version = "1.6.0";
13-
format = "setuptools";
12+
version = "2.0.0";
13+
pyproject = true;
1414

15-
src = fetchPypi {
16-
inherit pname version;
17-
sha256 = "76e4b03d700a641fd7761d3cd4fdbbdcd787eade1ebfac43f877016328334f78";
15+
disabled = pythonOlder "3.8";
16+
17+
src = fetchFromGitHub {
18+
owner = "falconry";
19+
repo = "python-mimeparse";
20+
tag = version;
21+
hash = "sha256-4LdfxVOioiyjeZjxCrvOELG+mJ4YOX4CUn+CXYWCtOo=";
1822
};
1923

20-
dependencies = lib.optionals (pythonAtLeast "3.13") [ legacy-cgi ];
24+
build-system = [ setuptools ];
2125

2226
nativeCheckInputs = [ pytestCheckHook ];
2327

2428
meta = with lib; {
2529
description = "Module provides basic functions for parsing mime-type names and matching them against a list of media-ranges";
2630
homepage = "https://github.com/dbtsai/python-mimeparse";
31+
changelog = "https://github.com/falconry/python-mimeparse/releases/tag/${version}";
2732
license = licenses.mit;
2833
maintainers = [ ];
2934
};

0 commit comments

Comments
 (0)