Skip to content

2026.9.30.1: a build names each package when it does work, one status row with a screen of dots, --play-game, and one lock entry per identity - #743

Merged
Sunrisepeak merged 17 commits into
mainfrom
feat/build-output-r3
Sep 30, 2026
Merged

Sunrisepeak merged 17 commits into
mainfrom
feat/build-output-r3

Conversation

@speak-agent

@speak-agent speak-agent commented Sep 29, 2026 •

Copy link
Copy Markdown
Member

Build output design revision 3 (.agents/docs/2026-09-30-build-output-refinement-design.md), from a report on mcpp build in the xlings repository with 2026.9.29.5, and two defects found while measuring it. Version 2026.9.30.1.

What was measured

A pseudo-terminal recording of a first build of xlings under strace --trace-fds=1,2, replayed write by write:

  • 184 of 202 frames left in two writes (stdout is line-buffered), and every line above the region in three (erase, text, redraw);
  • the status line was drawn 0.6 ms into the command and pushed down by each early line;
  • the cache pass ran unread, so a cache-served dependency never completed and the folded dependency line waited 27 s for ninja to exit;
  • the phase stayed on the build programs for 13 s of planning;
  • a planned build rewrote the committed mcpp.lock with a second entry per [dependencies.mcpplibs] key (since 2026.9.29.1).

Changes

  • Package lines. A package is named once, when it does work: Compiling at its first step that is not a dependency scan (or its first check or prepare action), Cached … (N units) when the cache places its units. Nothing is folded; a package with nothing to do has no line (--verbose: Fresh, and Compiled with steps and span). A package inside the project is named by its short name, version and directory; any other by its identity, with (index …), (git …) or its relative directory; the name's colour states the source.
  • The live display. One status row, aligned with the verbs, drawn half a second in, each frame one write that overwrites in place with autowrap off for the row. last N running once ninja's %u reaches 0. A screen of 24 braille cells (mcpp.ui.dots_screen, one partition per animation) plays the chomper, the snake, the stack or the ions; MCPP_PROGRESS names one, or plain, or off.
  • --play-game[=snake|stack|runner] on build, run and test: a game on the screen, steered from the keyboard; the terminal's mode is restored on exit and, through the signal guard, on Ctrl-C.
  • Finished. The breakdown and longest from one minute (was ten seconds); a compile is named by its source file relative to its package (longest slow: src/main.cpp 1m08s); the fast path states the profile's descriptor, carried by the step record's header. One function, profile_descriptor, spells it for both paths.
  • Programs and failures. A build program has a line when it runs or fails; error: build failed in <package>; the phase returns to Planning after the programs.
  • W-b. A bare key of a path or git dependency states only the short name; its adoption of the declared namespace is not reported. A contradicting namespace is reported once per consumer manifest (package-identity §4.2).
  • The lock. One entry per identity, spelled as 2026.9.28.3 spelled it; a lock holding two is reduced to one (e2e 844; verified on the xlings repository: its committed lock stays byte-identical, and the 15 entries 2026.9.29.5 wrote return to 13).
  • Keys. The game reads keys only when mcpp is in the terminal's foreground (a background job that changed the mode would be stopped by SIGTTOU); a control sequence with parameters is decoded whole, so Ctrl-Up is Up and F5 is no key.
  • Repository layout. The Windows resource script of mcpp.exe moves from res/ to docs/res/, the packaging and release scripts from scripts/ to tools/; the empty cdb.json committed by 2026.9.29.1 is removed.
  • The bundled xlings is 2026.9.30.1.

Tests

  • Unit: test_build_progress (21), test_dots_screen (11), test_platform_terminal (3).
  • e2e: 842, 843 revised; 844, 845 new; the tests that read revision 2's lines follow them.
  • 842, 843, 844 and 845 fail with the released 2026.9.29.5 and pass with this branch.

… it, and a planned build of a workspace leaves a committed lock unchanged

In a workspace plan state.m is the virtual root, so the lock name of a root-declared index dependency fell through to the qualified name (cmdline) instead of the root's map key (mcpplibs.cmdline), and the hash, taken over the spelled name, changed with it. The partial-workspace merge keyed prior entries by the spelled name and kept the old entry beside the new one. The name is now looked up in the workspace root's and the selected members' manifests, the merge and the --locked comparison work on (namespace, short name), and a lock that holds one identity twice keeps its first entry. Adds e2e 844.
…d a key that contradicts the declared namespace is reported once per consumer manifest

Adopting the namespace a path or git manifest declares corrects nothing when the key wrote no namespace, so it is no longer reported. A key that writes a namespace (a namespace table or a dotted key) which the manifest contradicts is still reported; the reports are collected during the graph walk and emitted after resolution, one per consumer manifest and declared namespace, naming the manifest by its path relative to the project root, listing the keys, with a hint in TOML. Adoption itself is unchanged. package-identity.md 4.2 gains the scope clause; e2e 679 and 713 are revised and 679 gains a grouped-warning leg.
…gress design), under review

The design records the measurements of a report on mcpp build in the xlings repository with 2026.9.29.5 (a frame reaches the terminal in two or three writes; the status line is drawn before anything is known; cache-served dependencies never complete, so the folded dependency line is late; the phase stays on the build programs), the review rounds that settled the identity rule W-b, one line per package that does work, and one status row aligned with the verbs, and the open decisions on the status row's display.
…rawn in one write, aligned with the verbs, beside a screen of dots

Build output design revision 3 (.agents/docs/2026-09-30-build-output-refinement-design.md). A package's line is written when its first step finishes or its first check or prepare action starts: Compiling, or Cached with its units when the global cache serves it; nothing is folded, and the line never changes. The cache pass runs through the report as the build's first pass, so its steps count and cached packages are named as their units are placed. A package inside the project is named by its short name and directory, any other by its identity, the name coloured by its source. A build program has a line when it runs or fails. The phase returns to planning when the build programs end. A frame of the live region leaves in one write that overwrites the old rows in place, with autowrap off for the status row; the row is first drawn half a second into the command, aligned with the verbs, and states the last steps running once ninja has none left to start. The status row's screen (mcpp.ui.dots_screen, one partition per animation) plays the chomper, the snake, the stack or the ions, chosen per command; MCPP_PROGRESS names one, or plain, or off. The step record is version 2; a version 1 record is read as before.
… animations, mcpp.ui.dots_screen, and --play-game
…2e tests read the lines of revision 3

A game is an animation steered from the keyboard (mcpp.ui.dots_screen:snake_game, :stack_game, :runner_game) at a speed of its own; --play-game chooses one, --play-game=NAME names one, and without the option the status row plays the four animations as before. Keys are read from the terminal without echo or line ends while Ctrl-C still interrupts; the mode is restored when the report closes and, through the signal guard that kills ninja's group, when a signal ends mcpp. The game is off, with a line saying why, where standard input or output is not a terminal. A package is named at its first step that is not a scan, so a consumer no longer precedes the package it imports; its source comes from the resolution's record, so a package reached through [feature-deps] is named as the path package it is; a path or git package is named without the default namespace it takes; a cached package's unit count joins the origin's parentheses. The e2e tests that proved a program's cache hit read it under --verbose, where a reused program is stated; e2e 845 plays through a pseudo-terminal.
…ocs/res, the packaging and release scripts to tools, and the empty cdb.json committed by 2026.9.29.1 is removed
…S revokes the slave side for everyone else once the session leader exits
…CANON is turned back on and the next read clears
…equence with parameters is decoded whole

A background job that changed the terminal's mode would be stopped by
SIGTTOU; the game is off there and the line that says so names the
foreground. The key decoder reads the parameter bytes of a control sequence
before its final byte, so Ctrl-Up is Up and F5 is no key, where the tail of
either was read as keys; the decoder is exported and has unit tests.
MCPP_PROGRESS is compared without case when a game is chosen, as it is when
an animation is chosen.
…t taken, and what of T4 and T6 is therefore not implemented
…gest compile by its source file, and states the profile's descriptor on the fast path

Build output design revision 3, decision D4 (section 7.3). Below a minute
Finished states the profile and the total alone. The step record carries,
per compile step, its first input relative to the innermost package root
that holds it, and Finished names the longest step by it
(longest slow: src/main.cpp 1m08s) where it named the object file. The
record's header carries the profile's descriptor, which the fast path reads
alone, so a build with nothing to do states [unoptimized + debuginfo] as a
full build does. One function, profile_descriptor, spells the descriptor
for both, from the plan's manifest that compute_flags reads. The docs, the
CHANGELOG and the design state it; D3 is recorded as no change.
@Sunrisepeak
Sunrisepeak merged commit cc24173 into main Sep 30, 2026
49 of 51 checks passed
Sunrisepeak added a commit to openxlings/xim-pkgindex that referenced this pull request Sep 30, 2026
mcpp 2026.9.30.1 (mcpp-community/mcpp#743): the four platform archives, mirrored to xlings-res on GitHub and GitCode, with their sha256.
Sunrisepeak added a commit to mcpplibs/mcpp-index that referenced this pull request Sep 30, 2026
…9.30.1 (#492)

mcpp 2026.9.30.1 (mcpp-community/mcpp#743) is released and indexed (openxlings/xim-pkgindex#912). The full sweep with it (run 36651996579) passed: 28 jobs succeeded and 1 was skipped. min_mcpp is unchanged.
@Sunrisepeak
Sunrisepeak deleted the feat/build-output-r3 branch September 30, 2026 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants