Skip to content

Fix CI: make font-scan regression wait native-only - #1

Merged
richard1912 merged 3 commits into
richard1912:fix/font-scan-at-startupfrom
scottcampbelldata:fix/pr-974-native-font-scan-wait
Oct 13, 2026
Merged

richard1912 merged 3 commits into
richard1912:fix/font-scan-at-startupfrom
scottcampbelldata:fix/pr-974-native-font-scan-wait

Conversation

@scottcampbelldata

@scottcampbelldata scottcampbelldata commented Oct 13, 2026 •

Copy link
Copy Markdown

The regression test added in storytold#974 makes CI fail because it calls Instant::now, which the repository forbids on paths that may reach wasm.

Replace its clock-based wait with a bounded native-only poll. Keep the font-scan assertion; wasm takes the synchronous no-scan path without sleeping or reading a clock. The original font-scan implementation stays intact.

Validation in Ubuntu 24.04 / Rust 1.99.0:

  • Original head 8364cb379a24b5e42d034b2af3bdbbc686d29e2a: cargo clippy -p gridcraft-ui-egui --test font_scan_starts -- -D warnings reproduces the disallowed Instant::now failure.
  • Repaired head 497304e66335f186769d2de607485c3be2811a57: cargo xtask ci passes all eight gates (fmt, Clippy, native tests, assets, dependency layers, wasm, parity and keytips). The font-scan regression assertion remains and passes.
  • git diff --check passes.

The separate Windows font-binding race described in the original PR is outside this test-only repair; no Windows GUI behavior is claimed verified here.

This follow-up targets fix/font-scan-at-startup so the repair can be incorporated into the existing upstream PR.

richard1912 and others added 2 commits October 13, 2026 21:22
The desktop and web apps call setup_context_for_language directly, not
setup_context, so fonts::start_scan never ran: the font catalog stayed
empty, the Format Cells font list showed only the standard names and cells
formatted with an installed font couldn't render in it. Start the scan
there too (once; later calls and wasm are no-ops).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ut3hr3a13szpQdQ7gbYbfc
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