b85c12cf9af0ee1a954b8cced961bcbd909b7979 lrnassar Wed Apr 29 12:04:36 2026 -0700 Expand dbVar tracks to expose all six nstd186 source studies and add new Somatic and Other composites. refs #37406 Restructure the dbVar supertrack: - Renamed from "dbVar Common Struct Var" to "dbVar Struct Var". - dbVar Common SV: added subtracks for Lee, Abel, and Byrska-Bishop (the three nstd186 source studies that were missing from our Curated Common track), and for the American/East Asian/South Asian/Other populations. - dbVar Conflict SV: description page refreshed; subtrack longLabel clarified. - dbVar Somatic SV (new): single subtrack pulling somatic_sv.bb from the dbVar hub. Default hidden. - dbVar Other SV (new): residual bucket for dbVar SVs not classified as common, somatic, or clinical, split into Healthy and Phenotype subtracks. Default hidden. NCBI sometimes calls this "presumed normal"; the description page notes the equivalence. mergeSpannedItems on for the dense subtracks (normal_healthy ~5.6M items, normal_phenotype ~410K, somatic_sv ~67K). - ClinVar SVs are not duplicated; description pages cross-link to the existing ClinVar track instead. Description pages: rewrite dbVarCommon.html and dbVarCurated.html, refresh dbVarConflict.html, add dbVarSomatic.html and dbVarOther.html. Retire the unused dbVar_common.html. Methods links now point at NCBI's dbVar Overview rather than the FTP directory listing. searchTable termRegex widened to ^[den]ssv[0-9]+ so dssv* accessions in normal_healthy resolve. Otto: stage downloads to release/\${db}.new/, validate per file (size floor and 10% itemCount delta vs the current live copy), then atomically swap via directory rename with a one-cycle .prev rollback. On validation failure, leave .new/ in place for human inspection and exit non-zero so the wrapper emails. On no-op runs the wrapper now stays silent. checkNstd175.sh's "update done" message moved inside the update branch so silence is honoured. New-file detection (via a knownFiles.txt manifest) emails when NCBI adds a file we don't yet expose. knownFiles.txt itself lives only at the deployment path under /hive/data/outside/otto/dbVar/, not in the tree. diff --git src/hg/utils/otto/dbVar/dbVarWrapper.sh src/hg/utils/otto/dbVar/dbVarWrapper.sh index 23caa11318c..df428ed25b5 100755 --- src/hg/utils/otto/dbVar/dbVarWrapper.sh +++ src/hg/utils/otto/dbVar/dbVarWrapper.sh @@ -1,8 +1,27 @@ #!/bin/sh -e +# Do not modify this script, modify the source tree copy: +# src/hg/utils/otto/dbVar/dbVarWrapper.sh +# Install via 'make install' in that directory. + PATH=/cluster/bin/x86_64:$PATH EMAIL="otto-group@ucsc.edu" WORKDIR="/hive/data/outside/otto/dbVar" cd $WORKDIR -./checkDbVar.sh $WORKDIR 2>&1 | mail -s "dbVar Build" $EMAIL + +# Capture checkDbVar.sh output. Only email when there's something to report +# (hub update detected, new files in hub, or error). No-op runs stay silent. +TMPLOG=$(mktemp --tmpdir=${WORKDIR} dbVarBuild.XXXXXX) +trap "rm -f $TMPLOG" EXIT + +if ./checkDbVar.sh $WORKDIR > $TMPLOG 2>&1; then + if [ -s $TMPLOG ]; then + mail -s "dbVar Build" $EMAIL < $TMPLOG + fi +else + # The build errored out. The ERR trap inside checkDbVar.sh will have + # echoed its failure message; email whatever output we captured. + mail -s "dbVar Build FAILED" $EMAIL < $TMPLOG + exit 1 +fi