a71215bcc4a26e1641770d82127dc57ced1842c8
braney
  Tue Mar 10 12:37:04 2026 -0700
Detect tracks that list themselves as their own parent, preventing infinite loop refs #35986

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

diff --git src/hg/utils/hubCheck/tests/makefile src/hg/utils/hubCheck/tests/makefile
index 06a7e3df121..d7d5bd4287a 100644
--- src/hg/utils/hubCheck/tests/makefile
+++ src/hg/utils/hubCheck/tests/makefile
@@ -1,21 +1,21 @@
 kentSrc = ../../../..
 include ../../../../inc/common.mk
 
 hubCheck = ${DESTBINDIR}/hubCheck
 
-test:: one two errors supertrackChild genomesErrors badType badSubgroups autoScale noLongLabel badGroups goodGroups noCompositeGroup allowWarnings seqNameCheck noSeqNameCheck
+test:: one two errors supertrackChild genomesErrors badType badSubgroups autoScale noLongLabel badGroups goodGroups noCompositeGroup allowWarnings seqNameCheck noSeqNameCheck selfParent
 	${MAKE} clean
 
 one:	mkout
 	-${hubCheck} input/hub1.txt > output/output1.txt
 	diff expected/output1.txt output/output1.txt
 
 two:	mkout
 	-${hubCheck} input/hub2.txt > output/output2.txt 2> /dev/null
 	diff expected/output2.txt output/output2.txt
 
 supertrackChild: mkout
 	-${hubCheck} input/supertrackChild.txt > output/supertrackChild.txt 2> /dev/null
 	diff expected/supertrackChild.txt output/supertrackChild.txt
 
 errors:	mkout
@@ -54,20 +54,24 @@
 	-${hubCheck} input/noCompositeGroup.txt > output/noCompositeGroup.output.txt 2>/dev/null
 	diff expected/noCompositeGroup.output.txt output/noCompositeGroup.output.txt
 
 allowWarnings: mkout
 	${hubCheck} -allowWarnings input/supertrackChild.txt > output/allowWarnings.output.txt 2> /dev/null
 	diff expected/allowWarnings.output.txt output/allowWarnings.output.txt
 
 seqNameCheck: mkout
 	-${hubCheck} input/seqNameHub.txt > output/seqNameCheck.output.txt 2>/dev/null
 	diff expected/seqNameCheck.output.txt output/seqNameCheck.output.txt
 
 noSeqNameCheck: mkout
 	-${hubCheck} -noSeqNameCheck input/seqNameHub.txt > output/noSeqNameCheck.output.txt 2>/dev/null
 	diff expected/noSeqNameCheck.output.txt output/noSeqNameCheck.output.txt
 
+selfParent: mkout
+	-${hubCheck} input/selfParent.txt > output/selfParent.output.txt 2>/dev/null
+	diff expected/selfParent.output.txt output/selfParent.output.txt
+
 mkout::
 	@mkdir -p output
 clean::
 	rm -rf output