hsmusic / hsmusic-data

Data files for https://hsmusic.wiki — track, album, artist & flash info, etc
4 stars 10 forks source link

Happy Hospital references itself #489

Open Niklink opened 2 months ago

Niklink commented 2 months ago

It just does. Maybe should be an error check on the wiki code side to check self references/samples?

Thanks, mehbark!

towerofnix commented 2 months ago

not certain on wiki-side error—if we allow directed cycles (i.e. circles/loops: A refs B, B refs A; #hsmusic-chat), then constraint "no self-referencing" feels inconsistently specialized. better to locate via occasional check in REPL:

> trackData.filter(t => t.referencedTracks.includes(t))
[
  Track "Happy Hospital" (track:happy-hospital) (#40 in Call and New V)
]

mandating acyclic graph via wiki-info.yaml flag would be OK & useful for other wikis (or even as default)—but likely inappropriate for hsmusic-data. could similarly have flag for self-references, allow wikis to customize as desired

# we'd do this in hsmusic-data
# since we don't exactly "prescribe" the meaning of refs
# at the scale of this dataset
Allow Tracks Referencing Selves: true
Allow Tracks Referencing Cycles: true

# if unspecified (e.g. new wikis)
# then you'd get errors as crop-up