Skip to content

[CLI] Keep the doctor themes check beside the app-theme checks - #7179

Merged
josephfarina merged 3 commits into
mainfrom
josephfarina/doctor-keep-themes-check
Oct 8, 2026
Merged

josephfarina merged 3 commits into
mainfrom
josephfarina/doctor-keep-themes-check

Conversation

@josephfarina

@josephfarina josephfarina commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

User need

astryx doctor --json reports a themes check on every project in 0.6.5 and 0.6.6, and doctor documents each check id as stable. Main dropped that check when the app-theme checks arrived, so a script that reads themes by id would stop finding it in the next patch.

What this does

  • Doctor reports themes again, in its released place right after version alignment, with the released id, label and fields.

  • Without a generated theme module, themes reports what it reported before:

    • warn when no @astryxdesign/theme-* package is installed;
    • warn when one is installed but the app's package.json names no theme in astryx.theme;
    • pass when it names one.

    The messages are the released ones. The fix text now names theme add --import.

  • With a generated theme module, themes reports the overall result of the app-theme checks. It passes only when every one of them passed. Otherwise it reports fail or warn and names the checks that need attention, or info and names the checks that could not prove their result.

  • theme-management and the theme-* checks are unchanged.

  • The pending release note no longer says the check was renamed, and a new note describes the kept check.

Compatibility

Compared with published 0.6.6 on the same project, the themes id, label, status, message and position are identical in each released state: no theme package, a package installed but not wired, and a package wired through astryx.theme. The differences:

  • The fix text names theme add --import, not the environment variable or the config file.
  • The ASTRYX_THEME variable, which the CLI does not read, no longer counts as a wired theme. A theme key in astryx.config.mjs never counted, in 0.6.6 either.
  • In a workspace, astryx.theme is read from the app's own package.json, the same file the CLI reads when it resolves the theme, rather than the package.json beside the root node_modules. An app whose own package.json names a theme now passes with hoisted packages; an app that relied on a theme named only in the root package.json now warns.

Testing

  • Full CLI suite: 384 files, 6,095 passed, 2 expected failures (the later commits change the release note and the rollup's pass condition)
  • Knowledge, Changeset, CLI structure, published type-surface, README, export, copyright and repository checks, and API to CLI parity
  • New cases pin themes (id, label, fields and statuses) with and without a generated theme module, the rollup's handling of checks that could not prove their result, and its single place right after version alignment in the doctor report. Removing themes from the report, or changing its label, fails them.

@vercel

vercel Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Oct 8, 2026 7:36pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Oct 8, 2026
@astracat-bot

astracat-bot Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Oct 8, 2026, 7:58 PM UTC

@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

📚 Storybook Preview

View Storybook for this PR

🧪 Sandbox Preview

View Sandbox for this PR

No new or modified components detected.

Bundle Size Summary

No component packages changed.

Accessibility Audit

Status: No accessibility violations detected.

Visual Regression

23 of 442 shot(s) changed.

A change here is a question, not a failure: check whether the after is the
picture you intended. Record that review on the PR. Baseline maintenance is an
explicit dispatch of CI; this report never rewrites the baseline or adds a release gate.

component story theme mode pixels
Selector Indicator Space Bottom Sheet Narrow End RTL neutral light 754,077
Selector Indicator Space Bottom Sheet Wide Start neutral light 740,188
Chat Full AI Chat probe light 155,733
Chat Full AI Chat probe dark 155,005
Chat Default neutral dark 33,205
Chat Default neutral light 32,876
Chat Empty State probe light 23,531
Chat Empty State probe dark 22,622
ChatAutoScroll Scroll Behavior Comparison neutral dark 15,378
ChatAutoScroll Scroll Behavior Comparison neutral light 14,107
Chat With Attachments probe light 13,229
Chat With Attachments probe dark 11,065
TableRowExpansion Detail Panel neutral dark 5,129
TableRowExpansion Detail Panel neutral light 4,050
SideNav Resizable in AppShell probe light 3,208
TableGroupedRows Default neutral light 2,133
TableGroupedRows Default neutral dark 2,116
Markdown Default probe dark 897
Markdown Default probe light 897
Markdown Default neutral dark 882

and 3 more.


Generated by PR Enrichment workflow | Storybook | Sandbox | View full report

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks — keeping the released themes check available by its stable id, instead of letting it disappear in the next patch, is the right compatibility call, and the restoration itself checks out: same package discovery, messages, statuses, and position after version alignment for projects without a generated theme module, with the spec-settled narrowing (ASTRYX_THEME and workspace-root wiring no longer count, astryx.theme read from the app's own package.json) clearly covered by the new release note.

One fix is needed in the new rollup for projects with a generated module: it can report pass saying every theme check passes while theme-stylesheet-imports is only info because imports in an unparseable file could not be proven paired with their stylesheets. Please pass the rollup only when every check it summarizes has passed, and name any non-passing check otherwise — I left the details inline at the pass condition.

[Automated review]

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving. Against published 0.6.6 on the same projects (no theme package, a package installed but not wired, one wired through astryx.theme, and a pnpm symlink install), doctor --json gives themes the same id, label, status, message and place, right after version-alignment, so a script that reads it by id keeps working. Only the fix text changes, to theme add --import.

The workspace and ASTRYX_THEME differences behave as the new Changeset says, and the #7154 note no longer claims a rename. Taking themes out of the report fails the new position test.

[Automated review]

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks — this keeps the released themes check available by its stable id instead of letting it disappear in the next patch, which is the right compatibility call.

I verified the restored check against the pre-removal behavior: same package discovery, messages, statuses, and position after version alignment for projects without a generated theme module, with the spec-settled narrowing (ASTRYX_THEME and workspace-root wiring no longer count, and astryx.theme is read from the app's own package.json) clearly covered by the new release note. With a generated module, the summary now passes only when every check it summarizes has passed — an unproven check yields an info summary naming it instead of claiming every theme check passes — and the new tests pin that case along with the exact legacy objects and report position. The theme-checks and doctor suites pass.

No changes requested from me.

[Automated review]

@josephfarina
josephfarina merged commit d78473f into main Oct 8, 2026
44 checks passed
@github-actions
github-actions Bot deleted the josephfarina/doctor-keep-themes-check branch October 9, 2026 06:25

This branch was successfully deployed

1 active deployment
Preview — cae3fe7e Deployed Oct 8, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant