File: no_pkg_resources.patch

package info (click to toggle)
snakemake 7.32.4-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 25,832 kB
  • sloc: python: 32,846; javascript: 1,287; makefile: 247; sh: 163; ansic: 57; lisp: 9
file content (20 lines) | stat: -rw-r--r-- 630 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Description: Stop using pkg_resources

Author: Rebecca N. Palmer <rebecca_palmer@zoho.com>
Bug-Debian: https://bugs.debian.org/1083775
Forwarded: no

--- a/snakemake/utils.py
+++ b/snakemake/utils.py
@@ -466,9 +466,9 @@ def read_job_properties(
 
 def min_version(version):
     """Require minimum snakemake version, raise workflow error if not met."""
-    import pkg_resources
+    import packaging
 
-    if pkg_resources.parse_version(snakemake.__version__) < pkg_resources.parse_version(
+    if packaging.version.parse(snakemake.__version__) < packaging.version.parse(
         version
     ):
         raise WorkflowError(