Repository 'jbrowse2'
hg clone https://toolshed.g2.bx.psu.edu/repos/fubar/jbrowse2

Changeset 63:ac00dcfb5d1d (2024-03-28)
Previous changeset 62:ab0d6782a95f (2024-03-28) Next changeset 64:497fd2d27aa2 (2024-03-28)
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/jbrowse2 commit f450a9a7bec7ae695a85a061bf59956b73196976
modified:
jbrowse2.py
jbrowse2.xml
b
diff -r ab0d6782a95f -r ac00dcfb5d1d jbrowse2.py
--- a/jbrowse2.py Thu Mar 28 04:51:06 2024 +0000
+++ b/jbrowse2.py Thu Mar 28 07:46:04 2024 +0000
[
@@ -15,7 +15,7 @@
 import xml.etree.ElementTree as ET
 from collections import defaultdict
 
-logging.basicConfig(level=logging.DEBUG)
+logging.basicConfig(level=logging.INFO)
 log = logging.getLogger("jbrowse")
 
 JB2VER = "v2.10.3"
@@ -493,7 +493,7 @@
                     else:
                         try:
                             fl = urllib.request.urlopen(fapath + ".fai").readline()
-                        except:
+                        except Exception:
                             fl = None
                         if fl:  # is first row of the text fai so the first contig name
                             this_genome["genome_firstcontig"] = (
@@ -622,7 +622,6 @@
         # can be served - if public.
         # dsId = trackData["metadata"]["dataset_id"]
         # url = "%s/api/datasets/%s/display?to_ext=hic " % (self.giURL, dsId)
-        hic_path = trackData.get("hic_path", None)
         useuri = trackData["useuri"].lower() == "yes"
         if useuri:
             uri = data
@@ -682,7 +681,7 @@
         sampu = list(dict.fromkeys(samp))
         samples = [x.split(".")[0] for x in sampu]
         samples.sort()
-        logging.warn(
+        logging.debug(
             "$$$$ cmd=%s, mafss=%s samp=%s samples=%s"
             % (" ".join(cmd), mafss, samp, samples)
         )
@@ -737,7 +736,7 @@
         ]
         subprocess.check_call(cmd, cwd=self.outdir, stdout=gff3_unrebased)
         gff3_unrebased.close()
-        logging.warn("### blastxml to gff3 cmd = %s" % " ".join(cmd))
+        logging.debug("### blastxml to gff3 cmd = %s" % " ".join(cmd))
         return gff3_unrebased.name
 
     def add_blastxml(self, data, trackData, blastOpts, **kwargs):
@@ -749,7 +748,7 @@
                 cmd.append("--protein2dna")
             cmd.extend([os.path.realpath(blastOpts["parent"]), gff3])
             subprocess.check_call(cmd, cwd=self.outdir, stdout=gff3_rebased)
-            logging.warn("### gff3rebase cmd = %s" % " ".join(cmd))
+            logging.debug("### gff3rebase cmd = %s" % " ".join(cmd))
             gff3_rebased.close()
             # Replace original gff3 file
             shutil.copy(gff3_rebased.name, gff3)
@@ -1307,7 +1306,7 @@
                 track_types[tId] = track_conf["type"]
                 style_data = default_data["style"].get(tId, None)
                 if not style_data:
-                    logging.warn(
+                    logging.debug(
                         "### No style data in default data %s for %s"
                         % (default_data, tId)
                     )
@@ -1488,7 +1487,6 @@
             }
             for x in ass.findall("metadata/genomes/genome")
         ]
-        logging.warn("#!!! genomes=%s" % genomes)
         assref_name = jc.process_genomes(genomes)
 
         for track in ass.find("tracks"):
b
diff -r ab0d6782a95f -r ac00dcfb5d1d jbrowse2.xml
--- a/jbrowse2.xml Thu Mar 28 04:51:06 2024 +0000
+++ b/jbrowse2.xml Thu Mar 28 07:46:04 2024 +0000
b
b'@@ -541,7 +541,7 @@\n                 <assert_contents>\n                     <has_text text="genome path="></has_text>\n                    <has_text text="label="></has_text>\n-                    <has_text text="format="></has_text>\n+                    <has_text text="useuri="></has_text>\n                     <has_text text="metadata"></has_text>\n                 </assert_contents>\n             </output>\n@@ -576,7 +576,7 @@\n                     <has_text text="metadata"></has_text>\n                     <has_text text="useuri="></has_text>\n                     <has_text text="trackFile path="></has_text>\n-                    <has_text text="ext=&quot;bed&quot; label=&quot;test-3.bed&quot;"></has_text>\n+                    <has_text text="ext=&quot;vcf&quot; label=&quot;merlin.vcf&quot;"></has_text>\n                 </assert_contents>\n             </output>\n         </test>\n@@ -588,7 +588,7 @@\n                     <param name="genome.ext" value="fasta"/>\n                     <param name="genome.name" value="Merlin"/>\n                  </conditional>\n-                <repeat name="track_groups">\n+                 <repeat name="track_groups">\n                     <param name="category" value="Default" />\n                     <repeat name="data_tracks">\n                         <conditional name="data_format">\n@@ -611,11 +611,9 @@\n                         </section>\n                     </repeat>\n                 </repeat>\n-            </repeat>\n-\n-            <repeat name="track_groups">\n+                <repeat name="track_groups">\n                 <param name="category" value="Ignore Scale" />\n-                <repeat name="data_tracks">\n+                    <repeat name="data_tracks">\n                     <conditional name="data_format">\n                         <param name="data_format_select" value="gff"/>\n                        <conditional name="useuri">\n@@ -635,150 +633,148 @@\n                             </conditional>\n                         </section>\n                     </conditional>\n+                    </repeat>\n                 </repeat>\n-            </repeat>\n-\n-            <repeat name="track_groups">\n+                <repeat name="track_groups">\n                 <param name="category" value="Scaled Colour" />\n-                <repeat name="data_tracks">\n-                    <conditional name="data_format">\n-                        <param name="data_format_select" value="gff"/>\n-                       <conditional name="useuri">\n-                            <param name="insource" value= "history"/>\n-                            <param name="annotation" value="gff3/C.gff"/>\n-                        </conditional>\n-                        <conditional name="match_part">\n-                            <param name="match_part_select" value="false"/>\n-                        </conditional>\n-                        <section name="jbcolor_scale">\n-                            <conditional name="color_score">\n-                                <param name="color_score_select" value="score"/>\n-                                <param name="score_scaling" value="linear"/>\n-                                <conditional name="score_scales">\n-                                    <param name="scale_select" value="automatic"/>\n-                                </conditional>\n-                                <conditional name="color_scheme">\n-                                    <param name="score_scheme" value="opacity"/>\n-                                    <conditional name="color">\n-                                        <param name="color_select" value="automatic"/>\n+                    <repeat name="data_tracks">\n+                        <conditional name="data_format">\n+                            <param name="data_format_select" value="gff"/>\n+                           <conditional name="useuri">\n+                                <param name="insource" value= "history"/>\n+                                <param name="annotation"'..b'                   <repeat name="data_tracks">\n-                        <conditional name="data_format">\n-                            <param name="data_format_select" value="gff"/>\n-                            <conditional name="useuri">\n-                                <param name="annotation" value="gff3/1.gff"/>\n-                                <param name="insource" value= "history"/>\n-                            </conditional>\n-                            <conditional name="match_part">\n-                                <param name="match_part_select" value="false"/>\n-                            </conditional>\n-                            <section name="jbcolor_scale">\n-                                <conditional name="color_score">\n-                                    <param name="color_score_select" value="none"/>\n-                                </conditional>\n-                                <conditional name="color">\n-                                    <param name="color_select" value="automatic"/>\n-                                </conditional>\n-                            </section>\n-                            <section name="jbmenu">\n-                                <repeat name="track_menu">\n-                                    <param name="menu_action" value="iframeDialog"/>\n-                                    <param name="menu_label" value="Some menu item"/>\n-                                    <param name="menu_title" value="Frame title"/>\n-                                    <param name="menu_url" value="https://example.com/#!/?id={name}&amp;q={type}&amp;z=&quot;{end}&quot;"/>\n-                                    <param name="menu_icon" value="dijitIconNewTask"/>\n-                                </repeat>\n-                                <repeat name="track_menu">\n-                                    <param name="menu_action" value="newWindow"/>\n-                                    <param name="menu_label" value="Another menu item"/>\n-                                    <param name="menu_title" value="Frame title 2"/>\n-                                    <param name="menu_url" value="https://example.com/#!/?id={name}&amp;q={type}&amp;z=&quot;{end}&quot;"/>\n-                                </repeat>\n-                            </section>\n-                        </conditional>\n-                     </repeat>\n-                    <repeat name="data_tracks">\n-                        <conditional name="data_format">\n-                        <param name="data_format_select" value="gff"/>\n-                            <conditional name="useuri">\n-                             <param name="annotation" value="gff3/1.gff"/>\n-                             <param name="insource" value= "history"/>\n-                            </conditional>\n-                            <conditional name="match_part">\n-                                <param name="match_part_select" value="false"/>\n-                            </conditional>\n-                            <section name="jbcolor_scale">\n-                                <conditional name="color_score">\n-                                    <param name="color_score_select" value="none"/>\n-                                </conditional>\n-                                <conditional name="color">\n-                                    <param name="color_select" value="automatic"/>\n-                                </conditional>\n-                            </section>\n-                        </conditional>\n-                    </repeat>\n-            </repeat>\n-            </repeat>\n-            <param name="uglyTestingHack" value="enabled" />\n-            <output name="output">\n-                <assert_contents>\n-                    <has_text text="With menu or index"/>\n-                    <has_text text="gff"/>\n-                </assert_contents>\n-            </output>\n-        </test>\n+\n \n         <!-- TODO add a synteny test -->\n         <!-- TODO add a bam and a cram test -->\n'