You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Part of epic tracebloc/backend#1142 (Theme D — preflight parity). Follow-up from #372.
LOW/MED. The filename-column contract is now enforced at preflight for CSV manifests (ingestor IngestableRecordsValidator, data-ingestors PR #384; CLI CheckImageFilenameColumn, #373). A file-bearing category can also be ingested from a JSON manifest (source_type: json is independent of data_format), and that path has no equivalent preflight.
Gap
The ingestor's IngestableRecordsValidator is CSV-only by design — every check (_check_has_rows, _check_referenced_files, and the new _check_filename_column) no-ops on a non-CSV input. So a JSON manifest is never checked for the filename column.
The CLI (#373) is labels.csv-only too, so there's no JSON preflight on either side.
Note: data-ingestors #382 briefly covered this via a universal ingest-time remap, but it resolved the asymmetry the wrong way (case-insensitive accept) and was reverted by #384 in favor of the "filename only" (case-sensitive) contract. So JSON is back to long-standing pre-#382 behavior (fail-late), not a new regression.
Preferred fix (ingestor-side)
Extend the ingestor's preflight to the JSON manifest path: peek the first record's keys and apply the same exact-lowercase filename reject _check_filename_column already applies to CSV (case-sensitive, whitespace-lenient), so preflight and transfer agree for JSON too. Handle sparse records the way _resolve_label_column does (retry past a leading object that omits the key). Optionally mirror in the CLI if/when JSON manifests get a dry-run preview.
Repro
tb data ingest <dir> --task image_classification with a JSON manifest whose records use {"Filename": "...", "label": "..."} → dry-run/preflight passes, real ingest fails cluster-side with exit 9.
Part of epic tracebloc/backend#1142 (Theme D — preflight parity). Follow-up from #372.
LOW/MED. The
filename-column contract is now enforced at preflight for CSV manifests (ingestorIngestableRecordsValidator, data-ingestors PR #384; CLICheckImageFilenameColumn, #373). A file-bearing category can also be ingested from a JSON manifest (source_type: jsonis independent ofdata_format), and that path has no equivalent preflight.Gap
IngestableRecordsValidatoris CSV-only by design — every check (_check_has_rows,_check_referenced_files, and the new_check_filename_column) no-ops on a non-CSV input. So a JSON manifest is never checked for the filename column.record.get("filename"), so a JSON manifest whose records useFilename(case variant) or a wrong key (image_id) resolves toNoneand fails cluster-side with exit 9 ("No filename found in record") after the full upload — the exact accept-locally / fail-after-upload gap data ingest: "filename" column resolved case-insensitively at preflight but case-sensitively at transfer (#340-class) #372 closed for CSV.#373) islabels.csv-only too, so there's no JSON preflight on either side.Note: data-ingestors #382 briefly covered this via a universal ingest-time remap, but it resolved the asymmetry the wrong way (case-insensitive accept) and was reverted by #384 in favor of the "filename only" (case-sensitive) contract. So JSON is back to long-standing pre-#382 behavior (fail-late), not a new regression.
Preferred fix (ingestor-side)
Extend the ingestor's preflight to the JSON manifest path: peek the first record's keys and apply the same exact-lowercase
filenamereject_check_filename_columnalready applies to CSV (case-sensitive, whitespace-lenient), so preflight and transfer agree for JSON too. Handle sparse records the way_resolve_label_columndoes (retry past a leading object that omits the key). Optionally mirror in the CLI if/when JSON manifests get a dry-run preview.Repro
tb data ingest <dir> --task image_classificationwith a JSON manifest whose records use{"Filename": "...", "label": "..."}→ dry-run/preflight passes, real ingest fails cluster-side with exit 9.