[Documents skill] DOCX list restarts can continue in Word while LibreOffice render passes

Open 💬 0 comments Opened Aug 26, 2026 by alorl30

What version of the Codex App are you using?

Codex Desktop, current on 2026-08-26. Affected bundled Documents skill snapshot: 26.819.11345.

What subscription do you have?

Not relevant to the document-generation behavior.

What platform is your computer?

Windows x64. The generated DOCX was checked with LibreOffice rendering and Microsoft Word-compatible OOXML inspection.

What issue are you seeing?

The bundled Documents workflow can produce DOCX files where independent numbered lists continue numbering across unrelated chapters in Microsoft Word, even though LibreOffice renders the intended restarts.

Two related OOXML defects were observed:

  1. Multiple logical lists used different w:num instances but shared the same w:abstractNum, relying on w:lvlOverride/w:startOverride for restarts. LibreOffice honored the override, while Microsoft Word could retain shared numbering state and continue the counter.
  2. Intended bullet paragraphs could have no valid direct bullet numId, or inherit a style-level numbering definition that resolved to decimal formatting. A render-only check could therefore mask a bullet/number semantic mismatch.

In the reproduced report, one numbered sequence reached 81–82 and a later chapter began at 83 instead of restarting. During the repair investigation, a structurally valid but semantically wrong intermediate DOCX rendered intended bullets as decimal items.

This makes the current full-document LibreOffice render-and-inspect requirement insufficient as the only correctness gate for list semantics.

What steps can reproduce the bug?

  1. Generate a DOCX from Markdown containing:
  • a numbered list starting at 1;
  • an unrelated bullet list;
  • another independent numbered list starting at 1;
  • a deliberately continued numbered list starting at 5.
  1. Separate the logical lists with headings or ordinary paragraphs.
  2. Inspect word/numbering.xml and observe multiple w:num instances referencing one shared w:abstractNum, with restart values supplied through w:lvlOverride/w:startOverride.
  3. Also inspect ListBullet paragraphs; some generator variants put numId only on the style, while others can leave a missing or decimal-linked definition.
  4. Render through LibreOffice. The list restarts may appear correct.
  5. Open the same DOCX in Microsoft Word. An independent list can continue the previous counter, or an intended bullet list can display decimal markers.

A minimal sanitized regression fixture was validated locally with two independent numbered lists, a bullet list, and an intentional continuation beginning at 5.

What is the expected behavior?

  • Every independent numbered list starts at its source-defined value in Microsoft Word and LibreOffice.
  • Intentional continuations retain their explicit start value.
  • Bullet lists remain bullets.
  • Structural validation detects semantic list-style mismatches even when LibreOffice rendering appears correct.

Suggested fix

  1. Give every logical list its own w:num and its own w:abstractNum.
  2. Store the start value directly in w:lvl/w:start; do not depend on w:lvlOverride/w:startOverride for independent restarts.
  3. Resolve style-level numId when a paragraph has no direct numbering properties.
  4. Generate a valid independent bullet definition with w:numFmt="bullet" and a real bullet marker.
  5. When the DOCX originates from Markdown, compare DOCX list-paragraph semantics against the Markdown source so intended bullets cannot silently become numbered paragraphs.
  6. Add an OOXML regression test covering:
  • two independent numbered lists;
  • one bullet list;
  • one intentional numbered continuation starting at 5;
  • unique w:num and w:abstractNum IDs per logical list;
  • no w:lvlOverride;
  • expected numFmt and embedded start values.
  1. Keep render-and-inspect QA for layout, but make the OOXML structural/semantic audit a required numbering gate.

Validation of the proposed mitigation

A local global Documents companion skill now performs the normalization and audit described above. Its regression fixture passes, and the corrected 15-page report was visually inspected page by page:

  • independent numbered lists restart correctly;
  • an intentional sequence continues 5–10 and then 11–14;
  • two later recommendation lists each restart at 1;
  • all intended bullets remain bullets.

Impact

Medium severity, recurring document-correctness defect. Users can deliver a visually plausible LibreOffice-rendered document whose numbering is wrong when opened in Microsoft Word.

View original on GitHub ↗