M127 — AP203 DOCUMENT_FILE referenced with empty URI / path field

§12.8 (sub-class: AP203 document reference completeness)

P1 — silent data loss

spec-violation

Sources

Sender

deduced — PDM exporter that elided the URI when the source document was an internal-only artifact

Description

A `DOCUMENT_FILE` is referenced as a specification document but its identifier, name, and description fields are empty strings. Consumers cannot resolve the referenced document to any URI or path; the reference is effectively unreachable.

Reproducer recipe

`DOCUMENT_FILE('','','',doc_type)` referenced via `APPLIED_DOCUMENT_REFERENCE`.

Expected kernel behavior

detect empty document references; warn, drop the reference, or reject as malformed.

Notes

Synonyms: "AP203 doc URI missing", "empty document ref", "PDM dangling spec link".

Expected validation

occt=empty/empty gmsh=empty ifc=schema_n/a

Byte assertions

Tier-3 assertions

Live oracle output

No live oracle data — run _run_corpus to populate.

Fixture content

Show fixture bytes (with defect highlighting)
1ISO-10303-21;
2/* M127: AP203 DOCUMENT_FILE referenced with empty URI / path field */
3/* DEFECT: DOCUMENT_FILE('','','',doc_type) — identifier, name, description all empty */
4/* APPLIED_DOCUMENT_REFERENCE links the part to an unresolvable document */
5/* Consumers cannot retrieve the referenced spec because no URI or identifier exists */
6/* Per AP203 §5.4 DOCUMENT_FILE must have a non-empty identifier for resolution */
7/* Byte assertion: contains(b'CONFIG_CONTROL_DESIGN') */
8/* Byte assertion: contains(b'DOCUMENT_FILE') */
9/* Byte assertion: contains(b"DOCUMENT_FILE('','','',") */
10HEADER;
11FILE_DESCRIPTION(('M127: AP203 DOCUMENT_FILE with empty identifier name and description'),'2;1');
12FILE_NAME('M127.stp','2026-06-21T00:00:00',(''),(''),'cad-research-suite','','');
13/* Byte assertion: contains(b'CONFIG_CONTROL_DESIGN') */
14FILE_SCHEMA(('CONFIG_CONTROL_DESIGN { 1 0 10303 203 1 0 0 }'));
15ENDSEC;
16DATA;
17#1=APPLICATION_CONTEXT('configuration controlled 3D designs of mechanical parts and assemblies');
18#2=APPLICATION_PROTOCOL_DEFINITION('international standard',
19  'config_control_design',1994,#1);
20/* Standard unit context (mm) */
21#10=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.));
22#11=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.));
23#12=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT());
24#13=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(0.001),#10,
25  'distance_accuracy_value','maximum model space distance between geometric entities');
26#14=(GEOMETRIC_REPRESENTATION_CONTEXT(3)
27  GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#13))
28  GLOBAL_UNIT_ASSIGNED_CONTEXT((#10,#11,#12))
29  REPRESENTATION_CONTEXT('ctx','3D'));
30/* Document type for the referenced specification */
31#20=DOCUMENT_TYPE('specification');
32/* Byte assertion: contains(b'DOCUMENT_FILE') */
33/* Byte assertion: contains(b"DOCUMENT_FILE('','','',") */
34/* DEFECT: all three string fields are empty — document is unresolvable */
35/* A valid DOCUMENT_FILE would have: DOCUMENT_FILE('SPEC-001','Widget Spec','Rev A drawing',#20) */
36#21=DOCUMENT_FILE('','','',#20);
37/* Product being documented */
38#22=PRODUCT('PART-001','Widget','Precision widget',(#1));
39#23=PRODUCT_DEFINITION_FORMATION('A','Initial',#22);
40#24=PRODUCT_DEFINITION_CONTEXT(#1,'design');
41#25=PRODUCT_DEFINITION('release','',#23,#24);
42/* APPLIED_DOCUMENT_REFERENCE: links product definition to the empty DOCUMENT_FILE */
43#26=APPLIED_DOCUMENT_REFERENCE(#21,'specification',(#25));
44/* GEOMETRIC_CURVE_SET IS the model entity — OCC yields empty */
45#500=GEOMETRIC_CURVE_SET('ap203-document-file-empty-uri-path-field',
46  (#21,#22,#23,#25,#26));
47/* Product chain */
48#600=APPLICATION_CONTEXT('mechanical design');
49#601=PRODUCT_CONTEXT('',#600,'mechanical');
50#602=PRODUCT('M127','M127','M127',(#601));
51#603=PRODUCT_DEFINITION_FORMATION('','',#602);
52#604=PRODUCT_DEFINITION_CONTEXT(#600,'design');
53#605=PRODUCT_DEFINITION('','',#603,#604);
54#606=PRODUCT_DEFINITION_SHAPE('','',#605);
55#607=SHAPE_REPRESENTATION('',(#500),#14);
56#608=SHAPE_DEFINITION_REPRESENTATION(#606,#607);
57ENDSEC;
58END-ISO-10303-21;