Skip to content

fix: harden upgrade and hook checks#188

Open
bestdan wants to merge 7 commits into
mainfrom
codex-upgrade-upstream-hook-fixes
Open

fix: harden upgrade and hook checks#188
bestdan wants to merge 7 commits into
mainfrom
codex-upgrade-upstream-hook-fixes

Conversation

@bestdan
Copy link
Copy Markdown
Owner

@bestdan bestdan commented Mar 28, 2026

No description provided.

bestdan and others added 7 commits March 27, 2026 21:09
## Summary
- **Fix 6 TypeScript errors** in `codeowners/check.ts` and
`graphql/check.ts`: Add explicit null guards after `ensureCondition()`
calls (which call `process.exit` but don't narrow types), and add
undefined checks for regex match destructuring of `state`/`rawPath`
- **Fix Prettier formatting** in 3 files: line length violations in
`codeowners/check.ts`, `graphql/check.ts`, and `upgrade.test.ts`

## Test plan
- [x] `pnpm typecheck` passes (0 errors)
- [x] `pnpm lint` passes (ESLint + Prettier)
- [x] `pnpm format:check` passes

Supersedes #189 (rebased onto correct base branch).

https://claude.ai/code/session_01RobTdhpRAXuPkyQ8CknbWd
…bilities

Fix TS2345/TS18048 errors by adding null guards before getNewlyChangedFiles
calls in codeowners and graphql check commands. Update @typescript-eslint
(8.46→8.57), vitest (4.0→4.1), and add pnpm overrides for picomatch and
brace-expansion to resolve all audit findings.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…lify graphql suffixes

- Extract duplicated parseGitStatusEntries/getNewlyChangedFiles into src/utils/git-status.ts
- Add isValidGitRef validation for the ref parameter in upgradeFromGitHub
- Simplify GRAPHQL_GENERATED_SUFFIXES to use literal values instead of filtering
- Export new git-status utilities from src/index.ts

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

1 participant