8aab2eef34ec26b85186b0a274d6dad2b0a99ff5 max Tue May 6 06:17:54 2025 -0700 improving js error message, refs #26554 diff --git src/hg/js/hgTracks.js src/hg/js/hgTracks.js index 145ee8edd63..c30ab8b4dee 100644 --- src/hg/js/hgTracks.js +++ src/hg/js/hgTracks.js @@ -4463,31 +4463,31 @@ // this.cmd can be used to figure out which menu item triggered this. // this.id === appropriate track if we are retrieving just a single track. // update local hgTracks.trackDb to reflect possible side-effects of ajax request. var newJson = scrapeVariable(response, "hgTracks"); //alert(JSON.stringify(newJson)); // DEBUG Example var oldJson = hgTracks; var valid = false; var stripped = {}; if (!newJson) { stripJsEmbedded(response, true, stripped); if ( ! stripped.warnMsg ) - warn("hgTracks object is missing from the response"); + warn("An unexpected error has occurred. Please consider letting us know by emailing genome-www@soe.ucsc.edu with the steps you took that resulted in this state and any info on how we can reproduce it. For that, consider creating a session via My Data > My Sessions."); } else { if (this.id) { if (newJson.trackDb[this.id]) { var visibility = vis.enumOrder[newJson.trackDb[this.id].visibility]; var limitedVis; if (newJson.trackDb[this.id].limitedVis) limitedVis = vis.enumOrder[newJson.trackDb[this.id].limitedVis]; if (this.newVisibility && limitedVis && this.newVisibility !== limitedVis) // see redmine 1333#note-9 alert("There are too many items to display the track in " + this.newVisibility + " mode."); var rec = oldJson.trackDb[this.id]; rec.limitedVis = newJson.trackDb[this.id].limitedVis; rec.imgOffsetY = newJson.trackDb[this.id].imgOffsetY; vis.update(this.id, visibility);