55858fedabd0a942ed8639db3ea0fd5fcfd3104b chmalee Thu Feb 26 15:00:25 2026 -0800 Make hubApi wig table output behave like a bedgraph instead of having a top level key with the chromosome name that contains all the data, now there is a key with the trackName and then bedgraph like data of chrom,start,stop,value. Does not affect bigBed output which already worked this way. Clean up some missing 'let' declarations and fix some for loop logic in the download data in window feature, refs #36802,#36858 diff --git src/hg/hubApi/apiUtils.c src/hg/hubApi/apiUtils.c index 563514c93d0..182dec444f9 100644 --- src/hg/hubApi/apiUtils.c +++ src/hg/hubApi/apiUtils.c @@ -552,30 +552,37 @@ { if (startsWith(el->name, type)) { ret = TRUE; break; } } return ret; } void wigColumnTypes(struct jsonWrite *jw, char *track) /* output column headers for a wiggle data output schema */ { jsonWriteListStart(jw, track); +jsonWriteObjectStart(jw, NULL); +jsonWriteString(jw, "name", "chrom"); +jsonWriteString(jw, "sqlType", "varchar"); +jsonWriteString(jw, "jsonType", "string"); +jsonWriteString(jw, "description", "chromosome name"); +jsonWriteObjectEnd(jw); + jsonWriteObjectStart(jw, NULL); jsonWriteString(jw, "name", "start"); jsonWriteString(jw, "sqlType", "int"); jsonWriteString(jw, "jsonType", "number"); jsonWriteString(jw, "description", "chromStart: 0-based chromosome start position"); jsonWriteObjectEnd(jw); jsonWriteObjectStart(jw, NULL); jsonWriteString(jw, "name", "end"); jsonWriteString(jw, "sqlType", "int"); jsonWriteString(jw, "jsonType", "number"); jsonWriteString(jw, "description", "chromEnd: 1-based chromosome end position"); jsonWriteObjectEnd(jw); jsonWriteObjectStart(jw, NULL);