Dev copied Halden’s supplied fault-code file into boiler/ as halden-faults.js, and the controller
imports from it by name, as you’d import from a Python module copied into a package:
import { describe } from "#boiler/halden-faults.js";
The file ends with module.exports = { describe, FAULTS };, yet node digest.js logs/week-12 stops
before printing anything, as the digest loads the main boiler’s Halden controller. The error line of
the trace reads, wrapped for display:
SyntaxError: The requested module
'#boiler/halden-faults.js' does not provide
an export named 'describe'
Node picks each file’s module system from its name and its package: an .mjs file is an ES module, a
.cjs file is CommonJS, and a .js file follows the "type" in the nearest package.json. In Halden’s
project, with no type, .js files are CommonJS; this project says "module", so Halden’s
module.exports line is ordinary code, not an export. Python has one module system, so it never makes
this choice.