c4e77d5b638be84e6f6c5dbc4bcf6e47684831e8
braney
  Fri May 1 12:29:29 2026 -0700
hgConvert quickLift: don't list hidden composite subtracks as not liftable

validateTdbChildren walked every subtrack in a composite and reported any
non-liftable types in the user-facing warning, even subtracks the user had
not made visible. Skip subtracks where isParentVisible/isSubtrackVisible
is false so only tracks the user actually asked to lift are validated.

refs #37491

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

diff --git src/hg/lib/trackHub.c src/hg/lib/trackHub.c
index 2ff11af1d34..ff3abae0a3f 100644
--- src/hg/lib/trackHub.c
+++ src/hg/lib/trackHub.c
@@ -1790,34 +1790,35 @@
         view->subtracks = validateTdbChildren(cart, db,view->subtracks, badList);
 
         if (view->subtracks != NULL)
             {
             slAddHead(&validTdbs, view);
             if (view->visibility)
                 count++;
             }
         }
     }
 else
     {
     for(; tdb; tdb = nextTdb)
         {
         nextTdb = tdb->next;
+        if (!isParentVisible(cart, tdb) || !isSubtrackVisible(cart, tdb))
+            continue;
         if (validateOneTdb(db, tdb, badList))
             {
             slAddHead(&validTdbs, tdb);
-            if (isSubtrackVisible(cart, tdb))
             count++;
             }
         }
     }
 if (count)
     return validTdbs;
 
 return NULL;
 }
 
 static boolean validateTdb(struct cart *cart, char *db, struct trackDb *tdb, struct trackDb **badList)
 // make sure we only output track types that can
 // be quickLifted.  Return true if we any tracks survive
 {
 if (tdb->subtracks)