Conversation
📝 WalkthroughWalkthroughAdds a CodeRabbit monorepo governance file, updates example environment variables, adjusts GitHub Actions CI (new build and pr-checks jobs, permissions), removes Renovate config, tweaks the PR template, and adds a CI/lint Changes
Sequence Diagram(s)sequenceDiagram
participant Dev as Developer
participant Repo as Repository
participant GH as GitHub Actions
participant CR as CodeRabbit
Dev->>Repo: push branch / open PR
Repo->>GH: trigger workflows (pull_request)
GH->>GH: run lint, format, typecheck
GH->>GH: run build (after lint/format/typecheck)
GH->>GH: run pr-checks (labels/title/assignees)
GH->>CR: call CodeRabbit for auto-review/labels per `.coderabbit.yml`
CR->>Repo: suggest labels, reviewers, comments
GH->>Repo: block or allow merge based on checks
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested labels
🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches🧪 Generate unit tests (beta)
No actionable comments were generated in the recent review. 🎉 🧹 Recent nitpick comments
Comment |
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Fix all issues with AI agents
In @.env.example:
- Around line 19-23: Rename the ambiguous environment variable
DISCORD_WEBHOOK_REMINDERS_HACK to a clearer name (e.g.,
DISCORD_WEBHOOK_REMINDERS_HACKATHON) by updating .env.example and all code
references that read process.env.DISCORD_WEBHOOK_REMINDERS_HACK (or similar
config access) to use the new identifier; also reorder the keys alphabetically
in .env.example if you want to satisfy dotenv-linter (place REMINDERS_HACKATHON
before REMINDERS_PRE) and update any README or deployment config that documents
the variable name.
In @.github/workflows/ci.yml:
- Around line 48-58: The build job lacks an explicit permissions block; add a
minimal, explicit permissions YAML key to the build job (the job named "build")
to follow least-privilege practices—e.g., include a permissions mapping that
scopes token access to only what's required for a build (for example: contents:
read and packages: read, and only add id-token or write scopes if the build
actually needs them); update the "build" job's top-level keys (near
runs-on/needs/steps) to include this permissions block.
- Around line 60-74: The pr-checks job currently runs the
actions/github-script@v7 step without an explicit permissions block; add an
explicit permissions: {} entry to the pr-checks job definition so the job runs
with no GitHub token scopes (least-privilege). Update the pr-checks job YAML to
include permissions: {} at the same indentation level as runs-on and steps,
keeping the existing steps (including the actions/github-script@v7 usage and its
script) unchanged.
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Fix all issues with AI agents
In @.env.example:
- Line 8: Replace the AUTH_SECRET entry in .env.example with the
library-preferred BETTER_AUTH_SECRET variable name and populate it with a secure
example (a high-entropy string of at least 32 characters) so the example matches
the documented convention and prevents production errors; update the AUTH_SECRET
line to BETTER_AUTH_SECRET and use a long placeholder value (e.g., a 32+
character random-looking secret) to illustrate required entropy.
In @.github/PULL_REQUEST_TEMPLATE:
- Around line 9-13: Add a short, one-line example and guidance under the
"Issue(s):" heading in the pull request template showing how to reference issues
(e.g., include example syntaxes like "Fixes `#123`" and "Refs `#123`") so
contributors know how to auto-link and auto-close issues; update the block that
currently contains "Issue(s):" to include a brief example sentence and two
sample link formats to serve as guidance for proper issue linking.
In @.github/workflows/ci.yml:
- Line 71: Update the GitHub Action usage from actions/github-script@v7 to
actions/github-script@v8 by replacing the version token used in the workflow
step (the line containing "uses: actions/github-script@v7"); after changing, run
tests in a draft PR to validate behavior against Node.js 24, review the v8
breaking changes in the actions/github-script release notes, and ensure runner
versions meet the minimum required (v2.327.1+) for any self-hosted runners
before merging.
.env.example
Outdated
| # openssl rand -base64 32 | ||
| # https://next-auth.js.org/configuration/options#secret | ||
| BETTER_AUTH_SECRET="" | ||
| AUTH_SECRET="" |
There was a problem hiding this comment.
🧩 Analysis chain
🌐 Web query:
Better Auth library environment variable AUTH_SECRET configuration
💡 Result:
In Better Auth, the encryption/signing secret can be provided either via config or environment variables:
- Preferred env var:
BETTER_AUTH_SECRET(better-auth.com) - Also supported:
AUTH_SECRET(Better Auth will check both) (better-auth.com)
Typical .env / .env.local
BETTER_AUTH_SECRET=your-high-entropy-secret-at-least-32-charsOr pass it explicitly in code
import { betterAuth } from "better-auth";
export const auth = betterAuth({
secret: process.env.BETTER_AUTH_SECRET, // or process.env.AUTH_SECRET
});Requirements / behavior
- Use a high-entropy secret, minimum 32 characters; recommended generation:
(better-auth.com)
openssl rand -base64 32
- If neither env var is set, Better Auth falls back to a default secret during development, but in production it throws an error if the secret isn’t set. (better-auth.com)
Citations:
- 1: https://www.better-auth.com/docs/installation?utm_source=openai
- 2: https://www.better-auth.com/docs/reference/options?utm_source=openai
- 3: https://www.better-auth.com/docs/installation?utm_source=openai
- 4: https://www.better-auth.com/docs/reference/options?utm_source=openai
- 5: https://www.better-auth.com/docs/installation?utm_source=openai
- 6: https://www.better-auth.com/docs/reference/options?utm_source=openai
Use BETTER_AUTH_SECRET instead of AUTH_SECRET—it's the library's official variable name.
Better Auth prefers BETTER_AUTH_SECRET (the documented, canonical env var). While AUTH_SECRET is also supported, using the preferred convention ensures better maintainability and aligns with the library's documentation. Also populate with a secure example:
- AUTH_SECRET=""
+ BETTER_AUTH_SECRET="your-secret-here-min-32-chars-use-openssl-rand-base64-32"The secret must be at least 32 characters of high entropy in production—an empty string will cause errors in production deployments.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| AUTH_SECRET="" | |
| BETTER_AUTH_SECRET="your-secret-here-min-32-chars-use-openssl-rand-base64-32" |
🧰 Tools
🪛 dotenv-linter (4.0.0)
[warning] 8-8: [QuoteCharacter] The value has quote characters (', ")
(QuoteCharacter)
🤖 Prompt for AI Agents
In @.env.example at line 8, Replace the AUTH_SECRET entry in .env.example with
the library-preferred BETTER_AUTH_SECRET variable name and populate it with a
secure example (a high-entropy string of at least 32 characters) so the example
matches the documented convention and prevents production errors; update the
AUTH_SECRET line to BETTER_AUTH_SECRET and use a long placeholder value (e.g., a
32+ character random-looking secret) to illustrate required entropy.
|
Ready for review |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Fix all issues with AI agents
In @.github/workflows/ci.yml:
- Around line 76-83: The PR check script currently validates labels, assignees
and title but misses verifying the PR body links an issue; update the script
that references the pull_request object (variable pr) to also inspect pr.body
for an issue reference (e.g. patterns like /#\d+/,
/(closes|fixes|resolves)\s+#\d+/i, or a GitHub issue URL) and push an error into
the e array if none found; ensure the new message (e.g. "Missing linked issue in
PR body.") is added to e so core.setFailed still reports it along with the other
checks.
In `@apps/guild/src/env.ts`:
- Around line 11-12: The skipValidation flag currently uses !!process.env.CI
which disables env validation in all CI jobs; change its predicate to an
explicit opt-in like process.env.SKIP_ENV_VALIDATION === "true" (or keep the
existing lint check) so only jobs that set SKIP_ENV_VALIDATION skip
validation—update the skipValidation line (referencing skipValidation,
process.env.CI, process.env.npm_lifecycle_event) to something like
process.env.SKIP_ENV_VALIDATION === "true" || process.env.npm_lifecycle_event
=== "lint".
🧹 Nitpick comments (1)
.github/workflows/ci.yml (1)
51-67: Please validate the new build job in a fork/draft PR.This adds a new gating stage; running it in a draft/fork PR first reduces the risk of blocking main if the build or
.envsetup behaves differently in CI.As per coding guidelines: "Test workflow changes in a fork or draft PR first."
| skipValidation: | ||
| !!process.env.CI || process.env.npm_lifecycle_event === "lint", |
There was a problem hiding this comment.
Avoid blanket skip of env validation in CI.
CI is true for all jobs, so this disables validation for build/typecheck too, which can hide missing or malformed envs. Prefer an explicit flag (or lint-only) to keep validation in other CI jobs.
🔧 Suggested fix
skipValidation:
- !!process.env.CI || process.env.npm_lifecycle_event === "lint",
+ process.env.SKIP_ENV_VALIDATION === "true" ||
+ process.env.npm_lifecycle_event === "lint",If you still want CI to skip validation for specific jobs, set SKIP_ENV_VALIDATION=true only in those workflow steps.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| skipValidation: | |
| !!process.env.CI || process.env.npm_lifecycle_event === "lint", | |
| skipValidation: | |
| process.env.SKIP_ENV_VALIDATION === "true" || | |
| process.env.npm_lifecycle_event === "lint", |
🤖 Prompt for AI Agents
In `@apps/guild/src/env.ts` around lines 11 - 12, The skipValidation flag
currently uses !!process.env.CI which disables env validation in all CI jobs;
change its predicate to an explicit opt-in like process.env.SKIP_ENV_VALIDATION
=== "true" (or keep the existing lint check) so only jobs that set
SKIP_ENV_VALIDATION skip validation—update the skipValidation line (referencing
skipValidation, process.env.CI, process.env.npm_lifecycle_event) to something
like process.env.SKIP_ENV_VALIDATION === "true" ||
process.env.npm_lifecycle_event === "lint".
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In @.env.example:
- Around line 8-9: Update .env.example to satisfy dotenv-linter: remove
surrounding quotes from values for keys like BETTER_AUTH_SECRET and AUTH_SECRET
(and other quoted entries at the ranges noted), sort/normalize key ordering to
match the linter's expected order across the file, and ensure the file ends with
a single trailing newline; apply the same unquoted/value and ordering fixes to
the other flagged ranges (21-25, 32-34, 37, 48-51) so dotenv-linter no longer
emits warnings.
commit b4e3785 Author: Dylan Vidal <111909137+DVidal1205@users.noreply.github.com> Date: Sat Feb 7 17:50:41 2026 -0500 [#328] Update PR Workflow (#329) Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> commit 8751ca6 Author: Adrian Osorio Blanchard <osorioadrian04@gmail.com> Date: Sat Feb 7 17:07:19 2026 -0500 [#330] Form URL not signed in redirect (#331) commit c0f89b4 Author: DGoel1602 <rhygonfn@gmail.com> Date: Sat Feb 7 12:23:52 2026 -0500 chore: remove everything email-queue commit df04574 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 23:18:52 2026 -0500 chore: update .env.example commit ad63134 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 23:15:12 2026 -0500 fix: add @forge/email to blade commit e81a138 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 22:56:02 2026 -0500 fix: add early return in hacker data commit ce5a375 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 22:48:20 2026 -0500 fix: format + lint + typecheck commit b3d2be7 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 22:16:42 2026 -0500 fix: transition all emailing to listmonk commit 3a1e0d3 Author: DGoel1602 <rhygonfn@gmail.com> Date: Fri Feb 6 13:55:21 2026 -0500 feat: add email package
Why
We keep pushing bugs into production. We need better checks, tests, and code review!
What
Issue(s): #328
Adds a Build workflow and a PR validator. The new PR validator requires all PRs are up to repository standards:
[#XYZ] Etc Etc EtcAlso adds Code Rabbit!
Test Plan
Merge me twin
Checklist
db:pushbefore mergingSummary by CodeRabbit
Chores
Documentation