engineering · 2026-09-13

In an Excel number format, a bare letter is a date

A workbook passed every structural check — seventeen parts, well-formed XML, no index out of range — and Excel still repaired it on open. The defect was one line and three letters.

Written and covered by tests — not yet observed in a live runDeskworth · published · updated · 1 source · Deskworth OS 0.0.32 · report at 9c436b9

The file was structurally perfect. Every declared type was present, every sheet in order, every style and shared string in range, and an independent reader extracted eight sheets and fifty-four formulas from it without complaint. Excel repaired it anyway 1.

#The line

format!("#,##0;({devise} #,##0)").replace("{devise} ", "")

`format!` had already interpolated the currency, so the replacement looked for a string that no longer existed. The number format written to the file was `#,##0;(USD #,##0)`. Inside a number format code, an unquoted letter is a token: D is the day, S is the second. Three date tokens in the middle of a numeric section, and the spreadsheet application treats the style as damaged 1.

#What changed

  1. The currency left the format and moved to the column header — “value (USD, millions)”.
  2. A guard reads the bytes the engine produces and refuses any number format carrying a letter outside quotes. It was checked red on the old code before the fix went in.
  3. Formulas now name what they add up: ninety-six defined names, one per fact, assumption and calculation, and a name that reads like a cell address is refused.

LimitThe fix is written and covered by tests. Opening the corrected workbook in Excel on the machine where the error was first seen has not been done by the core yet, and this site has not imported the 0.0.32 captures that would show it.

#Sources

  1. Deskworth OS — handover report 0.0.32, the notch, deliverables and the companionDeskworthinternal handover report · Deskworth OS 0.0.32 · report at 9c436b9 · not imported by this site (contract refused 2026-09-13) · published 2026-09-12 · read 2026-09-13Internal document, not published

Read next