Skip to content

fix(projects): restore the regenerated webhook secret, switch to bun, add CI - #2

Merged
sabrydawood merged 3 commits into
masterfrom
ccr-463348c6-ulw3ws
Oct 28, 2026
Merged

sabrydawood merged 3 commits into
masterfrom
ccr-463348c6-ulw3ws

Conversation

@sabrydawood

@sabrydawood sabrydawood commented Oct 28, 2026 •

Copy link
Copy Markdown
Member

Description

  • Regression fix (SEC-H3). The v3.1 merge (16d8325) dropped the reveal state from the tabbed project page. Because the webhook secret is write-only, the server returns a regenerated secret only once, and the page no longer passed it to ProjectWebhookCard. The secret was lost, so GitHub webhooks broke after any regeneration. The reveal state is back, keyed by ProjectId so the secret never shows on another project's page. A new page test fails without this fix.
  • Lint. Five ESLint errors arrived with the v3.1 merge. Four type aliases were renamed to the T prefix. The notification card's server merge keeps its setState in the effect, with a reasoned exception, the same as the project form.
  • Bun only. bun.lock is the single lockfile, package.json pins packageManager: bun@1.4.4, and the README installs and runs with bun.
  • CI. The client had none. A new workflow runs on every PR and push to master: install with a frozen lockfile, then lint, test and build. Actions are pinned by SHA and checked with actionlint.

How it was tested

  • bun install --frozen-lockfile with no changes.
  • bun run lint: 0 errors.
  • tsc -b: 0 errors.
  • bun run test -- --run: 5 files, 10 tests, all passing. The 2 new tests fail on master.
  • bun run build: OK.

Notes

The server repo docs still show npm for the client in FAQ.md, migration-v2-to-v3.md and guides/GITHUB_SETUP.md. They will be updated in the server repo.

Summary by CodeRabbit

  • Bug Fixes
    • After regenerating a project’s webhook secret, the revealed value now appears on that project’s details page and clears when you switch to another project.
  • Documentation
    • Updated setup and command instructions to use Bun 1.4+ for installing dependencies and running development, build, and preview tasks.

The v3.1 merge dropped the reveal state from the tabbed project page,
so the secret the server returns once on regeneration was never shown
and was lost. Restore it, keyed by project, and add a page test that
fails if the card stops receiving it or shows it on another project.

Signed-off-by: Sabry Dawood <kazouya25@gmail.com>
Type aliases take the T prefix (TStatus, TDeliveryConfigInput,
TProviderConfigInput, TProjectTemplateCategory), and the notification
card's server merge keeps its setState in the effect with a reasoned
exception, as the project form already does.

Signed-off-by: Sabry Dawood <kazouya25@gmail.com>
bun.lock is the single lockfile and package.json pins bun@1.4.4. The
README installs and runs with bun. A CI workflow installs with a frozen
lockfile, then lints, tests and builds on every pull request and push
to master.

Signed-off-by: Sabry Dawood <kazouya25@gmail.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-10-28T11:42:18.142089Z
We couldn’t complete this review. Comment @codex review to try again.
f9fe5c1 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@coderabbitai

coderabbitai Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 84e3b529-cc51-46fa-b98d-88fab461588e
Commits

Reviewing files that changed from the base of the PR and between 16d8325 and f9fe5c1.

Files selected for processing: 13
  • .github/workflows/ci.yml
  • README.md
  • package.json
  • src/components/Settings/NotificationChannelsTab.tsx
  • src/components/Settings/NotificationProvidersTab.tsx
  • src/pages/Deployments/components/CopyLogButton.tsx
  • src/pages/Projects/ProjectDetailsPage.test.tsx
  • src/pages/Projects/ProjectDetailsPage.tsx
  • src/pages/Projects/components/ProjectNotificationsCard.tsx
  • src/pages/Projects/components/ProjectTemplateWizard.tsx
  • src/services/notificationChannelService.ts
  • src/services/notificationProviderService.ts
  • src/services/projectTemplateService.ts

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

Walkthrough

The change adds a Bun-based CI workflow and updates setup commands, scopes regenerated webhook secrets to the project that requested them, and renames several TypeScript types without changing their values or runtime logic.

Changes: Bun setup and CI

Layer / File(s) Summary
Bun version and project commands
package.json, README.md
The package metadata specifies Bun 1.4.4. The README updates prerequisites, installation, development, build, and preview commands to use Bun.
CI workflow
.github/workflows/ci.yml
The workflow runs on pull requests to master or version/** and pushes to master. It installs dependencies with a frozen lockfile, then runs lint, tests, and build.

Project webhook secret state

Layer / File(s) Summary
Store and display the regenerated secret
src/pages/Projects/ProjectDetailsPage.tsx, src/pages/Projects/ProjectDetailsPage.test.tsx
The page stores the returned secret with the request's project ID and passes it to the webhook card only when the displayed project matches. Tests cover displaying the secret and clearing it after a project change.

Type naming and lint adjustment

Layer / File(s) Summary
Rename service types and update consumers
src/services/notificationChannelService.ts, src/components/Settings/NotificationChannelsTab.tsx, src/services/notificationProviderService.ts, src/components/Settings/NotificationProvidersTab.tsx, src/services/projectTemplateService.ts, src/pages/Projects/components/ProjectTemplateWizard.tsx
Notification configuration and project-template category types receive new names. Their union values and consuming behavior remain unchanged.
Local type and lint adjustments
src/pages/Deployments/components/CopyLogButton.tsx, src/pages/Projects/components/ProjectNotificationsCard.tsx
CopyLogButton uses the renamed local status type. ProjectNotificationsCard adds an ESLint suppression for its seeded-state update.

Priority: Normal

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Bug fix

Possibly related PRs

Merge Risk: Minimal · up to f9fe5

The regenerated secret remains scoped to its project, and normal navigation discards it when leaving the details page. No actionable merge-blocking issue remains; merge after normal checks pass.

Pre-merge checks: Passed 5
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly summarizes the main changes: restoring the regenerated webhook secret, switching to Bun, and adding CI.
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 10 files. (3 skipped: 3 unsupported.)

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sabrydawood
sabrydawood merged commit 207bf48 into master Oct 28, 2026
2 checks passed
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