Skip to content

Commit 0afe509

Browse files
fix(app-shell): rename the deployment notice state module so it no longer differs from the component only in case (#34762)
<!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9R6fQuMSzSrRW2oowG4K2kQ)_ Part of #34705 Clause-②: no Metadata-protocol: none Skills-docs: none — an internal module rename; no skill page names either file. > The first of two PRs for #34705. This one is the fix (the rename), so macOS builds work as soon as it lands. The second adds the repository-wide gate (`check:module-name-case`, one step in `lint.yml`, which is Tier H under the workflows split); it is held until this one merges, because the gate is red on `main` until then. The second PR closes the card. ## 维护者速读 - **改了什么**:`ui/packages/app-shell/src/console/deployment-notice/deploymentNotice.ts` 改名为 `deploymentNoticeState.ts`,它的两个导入方(`DeploymentNotice.tsx` 和它的测试)跟着改。一处注释里的文件名同步。 - **为什么改**:同一目录里 `DeploymentNotice.tsx`(组件)和 `deploymentNotice.ts`(状态模块)只差大小写。在 macOS 默认的大小写不敏感文件系统上,`'../deployment-notice/DeploymentNotice.js'` 解析到了状态模块,`tsc` 构建 app-shell 失败(`TS2724`、`TS1261`)。 - **风险与回滚**:纯改名,包的导出不变,行为不变。回滚即撤回本 PR。 - **先看**:`DeploymentNotice.tsx:49` 的导入。 - **两分钟验证**:`cd ui && pnpm exec vitest run packages/app-shell/src/console/deployment-notice`,预期全绿;`git ls-files ui/packages/app-shell/src/console/deployment-notice` 里不再有两个只差大小写的名字。 - **需要你做的**:无;本 PR 走普通队列。 ## What changes - `deploymentNotice.ts` → `deploymentNoticeState.ts` (git rename, content unchanged). - `DeploymentNotice.tsx:49` and `__tests__/DeploymentNotice.test.tsx:31` import the new name; the docblock at `DeploymentNotice.tsx:27` names it. - `.changeset/34705-deployment-notice-state-module-name.md`: `@object-ui/app-shell` patch. The component's importers (`console/home/HomePage.tsx:39`, `views/DashboardView.tsx:40`, the HomePage tests' `vi.mock('../../deployment-notice/DeploymentNotice')`) already spell the component and are untouched: on a case-insensitive file system they now reach the only file of that name. ## Premise On `origin/main` f6f5b50 the folder holds `DeploymentNotice.tsx` and `deploymentNotice.ts`. The pair differs in extension too, so a lower-cased `git ls-files` dedupe finds nothing; compared by the name an import spells (extension removed), they collide. A scan of every tracked path on `main` by that rule finds exactly this pair, and none on this branch (25,990 paths). Reproduced from the tree, not on a macOS file system (the container's is case-sensitive). ## Verification See the final-head comment for the head this covers. ## Human Minimum - [x] 1. Schemas start as Zod; `packages/spec` holds no runtime logic. (No spec change.) - [x] 2. Every name I added uses the casing for its kind. - [x] 3. No formatter ran; `pnpm lint` passes. - [x] 4. One issue, one branch off an up-to-date `main`, one pull request. (The card's gate follows as a second PR, as stated above.) - [x] 5. A change that publishes carries a changeset, and both declaration lines are filled in here and in the changeset. - [x] 6. `packages/spec` touched: not touched. - [x] 7. No hand edits to `content/docs/references/`, `packages/*/CHANGELOG.md` or `content/docs/releases/`. - [x] 8. Title, body and comments are in English. (The 维护者速读 section is the maintainer's requested summary.) - [x] The *Before Submitting* list in CONTRIBUTING.md is done. --- 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01ADHkmSYe73LCZ6WxGFvcko <!-- signed: repo:objectstack#2 · os-steve · session_01ADHkmSYe73LCZ6WxGFvcko --> Co-authored-by: Claude <noreply@anthropic.com>
1 parent ba27c3b commit 0afe509

4 files changed

Lines changed: 14 additions & 3 deletions

File tree

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
fix(app-shell): the deployment notice's state module no longer shares its name with the component, so app-shell builds on a case-insensitive file system
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
Skills-docs: none — an internal module rename; no skill page names either file.
10+
11+
`ui/packages/app-shell/src/console/deployment-notice/` held `DeploymentNotice.tsx` (the component) and `deploymentNotice.ts` (its wire and storage), two names that differ only in letter case. On a case-insensitive file system, the default on macOS, `../deployment-notice/DeploymentNotice.js` resolved to the state module, so `tsc` failed the app-shell build (`TS2724`, `TS1261`). The state module is now `deploymentNoticeState.ts`, and its two importers follow. Nothing exported by the package changes.

‎ui/packages/app-shell/src/console/deployment-notice/DeploymentNotice.tsx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
*
2525
* On Home it sits in the page's 1120 px content column, like every other card
2626
* above the apps. It says nothing about mail: an unset email service is not a
27-
* finding this console draws (`deploymentNotice.ts`, objectstack#32643), and the
27+
* finding this console draws (`deploymentNoticeState.ts`, objectstack#32643), and the
2828
* first-run checklist's optional Email delivery row is where mail is set up.
2929
*
3030
* @module
@@ -46,7 +46,7 @@ import {
4646
type DeploymentFinding,
4747
type DeploymentNoticeState,
4848
type HideAnswer,
49-
} from './deploymentNotice.js';
49+
} from './deploymentNoticeState.js';
5050

5151
export interface DeploymentNoticeProps {
5252
/** `home`: nothing once hidden. `system-overview`: one small line once hidden. */

‎ui/packages/app-shell/src/console/deployment-notice/__tests__/DeploymentNotice.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ vi.mock('@object-ui/auth', async (importOriginal) => ({
2828

2929
import { DeploymentNotice } from '../DeploymentNotice';
3030
import { initRuntimeConfig, resetRuntimeConfigForTesting } from '../../../runtime-config';
31-
import { HIDDEN_KEY_PREFIX, deploymentVariablesText, parseDeploymentNotice } from '../deploymentNotice';
31+
import { HIDDEN_KEY_PREFIX, deploymentVariablesText, parseDeploymentNotice } from '../deploymentNoticeState';
3232

3333
const NOTICE = {
3434
production: true,

ui/packages/app-shell/src/console/deployment-notice/deploymentNotice.ts renamed to ui/packages/app-shell/src/console/deployment-notice/deploymentNoticeState.ts

File renamed without changes.

0 commit comments

Comments
 (0)