Étienne Mollier pushed to branch master at Debian Med / scoary
Commits: 3222d4ad by Étienne Mollier at 2024-10-16T17:18:20+02:00 rm-pkg_resources.patch: new: reimplement uses of pkg_resources. - - - - - 9cdaea23 by Étienne Mollier at 2024-10-16T17:18:45+02:00 d/control: remove dependency on python3-pkg-resources. Closes: #1083762 - - - - - 17f85885 by Étienne Mollier at 2024-10-16T17:19:16+02:00 Ready for upload to unstable. - - - - - 4 changed files: - debian/changelog - debian/control - + debian/patches/rm-pkg_resources.patch - debian/patches/series Changes: ===================================== debian/changelog ===================================== @@ -1,3 +1,10 @@ +scoary (1.6.16-9) unstable; urgency=medium + + * rm-pkg_resources.patch: new: reimplement uses of pkg_resources. + * d/control: remove dependency on python3-pkg-resources. (Closes: #1083762) + + -- Étienne Mollier <[email protected]> Wed, 16 Oct 2024 17:19:08 +0200 + scoary (1.6.16-8) unstable; urgency=medium * Team upload. ===================================== debian/control ===================================== @@ -20,7 +20,6 @@ Package: scoary Architecture: all Depends: ${misc:Depends}, ${python3:Depends}, - python3-pkg-resources, python3-scipy Suggests: roary Description: pangenome-wide association studies ===================================== debian/patches/rm-pkg_resources.patch ===================================== @@ -0,0 +1,71 @@ +Description: workaround removal of pkg_resources. +Author: Étienne Mollier <[email protected]> +Bug: https://github.com/AdmiralenOla/Scoary/issues/112 +Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1083762 +Last-Update: 2024-10-16 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- scoary.orig/scoary/GUI.py ++++ scoary/scoary/GUI.py +@@ -61,7 +61,7 @@ + except ImportError: + sys.exit("Could not find the main Scoary executable") + +-from pkg_resources import resource_string, resource_filename ++from importlib.metadata import distribution + + class ScoaryGUI(Tkinter.Tk): + """ +@@ -617,11 +617,12 @@ + """ + Sets all variables corresponding to --test in the methods script + """ ++ scoary_dist = distribution('scoary') + self.GPAentryVariable.set( +- str(os.path.join(resource_filename(__name__, 'exampledata'), ++ str(os.path.join(scoary_dist.locate_file('scoary'), 'exampledata', + 'Gene_presence_absence.csv'))) + self.TraitsentryVariable.set( +- str(os.path.join(resource_filename(__name__, 'exampledata'), ++ str(os.path.join(scoary_dist.locate_file('scoary'), 'exampledata', + 'Tetracycline_resistance.csv'))) + self.TreeentryVariable.set("") + self.RestrictVariable.set("") +--- scoary.orig/scoary/methods.py ++++ scoary/scoary/methods.py +@@ -27,7 +27,7 @@ + #import scoary + + import os +-from pkg_resources import resource_string, resource_filename ++from importlib.metadata import distribution + + #SCOARY_VERSION = scoary.__version__ + SCOARY_VERSION = __version__ +@@ -69,9 +69,10 @@ + if args.test: + args.correction = ['I','EPW'] + args.delimiter = ',' +- args.genes = os.path.join( +- resource_filename(__name__, 'exampledata'), +- 'Gene_presence_absence.csv') ++ scoary_dist = distribution('scoary') ++ args.genes = os.path.join(scoary_dist.locate_file('scoary'), ++ 'exampledata', ++ 'Gene_presence_absence.csv') + args.grabcols = [] + args.max_hits = None + args.newicktree = None +@@ -82,9 +83,9 @@ + args.restrict_to = None + args.start_col = 15 + args.threads = 4 +- args.traits = os.path.join( +- resource_filename(__name__, 'exampledata'), +- 'Tetracycline_resistance.csv') ++ args.traits = os.path.join(scoary_dist.locate_file('scoary'), ++ 'exampledata', ++ 'Tetracycline_resistance.csv') + args.upgma_tree = True + args.write_reduced = False + args.no_time = False ===================================== debian/patches/series ===================================== @@ -1,3 +1,4 @@ python3.11.patch scipy-1.12.0.patch remove_six.patch +rm-pkg_resources.patch View it on GitLab: https://salsa.debian.org/med-team/scoary/-/compare/b4a9b51dbbefb50b52ef476fe874f4065d30aea5...17f8588573d2ff6ee1caf0223d4714c5ecea81aa -- View it on GitLab: https://salsa.debian.org/med-team/scoary/-/compare/b4a9b51dbbefb50b52ef476fe874f4065d30aea5...17f8588573d2ff6ee1caf0223d4714c5ecea81aa You're receiving this email because of your account on salsa.debian.org.
_______________________________________________ debian-med-commit mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-med-commit
