fix: batch remediation - resolve 12 open issues - #72
Conversation
- Fix #56: Create CHANGELOG.md and PR/issue templates - Fix #57: Update CodeQL to autobuild for JS/TS and Rust - Fix #58: Remove unwrap panic in torrential download.rs - Fix #59: Document console.error in client-side error handler - Fix #46: Remove @ts-expect-error by aligning authMecs type - Fix #47: Add content-collections typegen script for sites/promo - Fix #49: Update starlight-links-validator to Astro 7 compatible - Fix #50: Add prettier-plugin-astro to sites/docs - Fix #55: Replace OSV-Scanner reusable workflow with CLI - Fix #62: Complete jsonwebtoken → jose migration - Fix #63: Pin all Tauri sub-crate wildcard dependencies Closes #46, #47, #49, #50, #55, #56, #57, #58, #59, #62, #63
|
Note
|
| Layer / File(s) | Summary |
|---|---|
Contribution templates and changelog .github/ISSUE_TEMPLATE/*, .github/PULL_REQUEST_TEMPLATE.md, CHANGELOG.md |
Adds structured issue and pull request forms and an Unreleased changelog section. |
Security workflow execution .github/workflows/codeql.yml, .github/workflows/osv-scanner.yml |
Enables Rust autobuild analysis and updates scheduled and pull-request OSV-Scanner execution. |
Dependency and site tooling updates
| Layer / File(s) | Summary |
|---|---|
Desktop dependency constraints desktop/src-tauri/**/Cargo.toml |
Replaces wildcard Rust dependency versions with explicit releases while preserving existing features and paths. |
Site package and generation updates sites/docs/package.json, sites/promo/package.json |
Updates the documentation link validator and changes site type-generation scripts. |
Server authentication and state typing
| Layer / File(s) | Summary |
|---|---|
JWT verification migration server/server/internal/clients/event-handler.ts, server/package.json |
Replaces jsonwebtoken verification with jose certificate-key import and caught verification failures. |
Users state contract server/composables/users.ts |
Removes id from authMecs state entries and removes the fetch type suppression. |
Client error handler documentation server/plugins/error-handler.ts |
Documents client-side console logging and server-side logging boundaries. |
Backend construction error handling
| Layer / File(s) | Summary |
|---|---|
Backend configuration validation torrential/src/downloads/download.rs |
Returns an internal server error and logs a warning when backend configuration is absent instead of unwrapping and panicking. |
Estimated code review effort: 3 (Moderate) | ~25 minutes
Possibly related PRs
- BillyOutlast/drop#41 — Also changes OSV-Scanner workflow references.
Suggested reviewers: invalid-email-address
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Out of Scope Changes check | Workflow, template, changelog, dependency, and other code changes are unrelated to [#46] and appear out of scope. |
Move unrelated CI/docs/dependency updates to separate PRs or link the issues they address. |
✅ Passed checks (4 passed)
| Check name | Status | Explanation |
|---|---|---|
| Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. |
| Title check | ✅ Passed | The title is concise and accurately describes the batch remediation work resolving multiple issues. |
| Linked Issues check | ✅ Passed | The users.ts change removes the suppression and aligns state typing with the API payload, matching [#46]. |
| Docstring Coverage | ✅ Passed | Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. |
✨ Finishing Touches
📝 Generate docstrings
- Create stacked PR
- Commit on current branch
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Commit unit tests in branch
fix/issue-remediation-batch
Comment @coderabbitai help to get the list of available commands.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Greptile SummaryBatch remediation PR closing 11 open issues across CI workflows, Rust safety, TypeScript/Prisma alignment, and site dependencies. The changes are largely mechanical and low-risk, with most fixes being straightforward pin/type/dependency corrections.
Confidence Score: 4/5Safe to merge after fixing the mutable-tag reference in the OSV-Scanner PR workflow. The vast majority of changes are clean, mechanical fixes. The one issue is in Files Needing Attention: Important Files Changed
|
There was a problem hiding this comment.
Actionable comments posted: 6
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/ISSUE_TEMPLATE/bug.yml:
- Around line 88-93: Update the logs textarea in the bug issue template,
identified by id “logs,” to explicitly instruct reporters to redact tokens,
passwords, private keys, and personal information before submitting logs
publicly. Preserve the existing label and shell rendering configuration.
In @.github/workflows/osv-scanner.yml:
- Around line 23-28: Update both workflow jobs to pin the actions/checkout step
and google/osv-scanner-action/osv-scanner-cli step to their complete immutable
commit SHAs instead of the mutable v4 and v2.3.8 references, preserving the
existing action versions and configuration.
In `@server/server/internal/clients/event-handler.ts`:
- Around line 47-49: Update JWT_TIME_WIGGLE and its use in the jwtVerify call so
clockTolerance is expressed in seconds, preserving the intended 30-second
tolerance rather than passing milliseconds.
- Around line 45-50: Update the certificate key import in the event-handler JWT
verification flow to use jose.importX509() for certBundle.cert instead of
jose.importSPKI(). Preserve the existing ES384 algorithm and jwtVerify
clockTolerance behavior, ensuring certificate import failures remain handled by
the current authentication failure path rather than surfacing as 500 errors.
In `@sites/docs/package.json`:
- Line 20: Update the `@astrojs/starlight` dependency in sites/docs/package.json
to version ^0.41.0 or newer before retaining the starlight-links-validator
^0.25.2 dependency.
In `@sites/promo/package.json`:
- Line 14: Update the typegen:sanity script so ./src/sanity/extract.json is
removed whether sanity typegen generate succeeds or fails. Wrap the existing
schema extraction and type generation commands with cleanup handling, preserving
the command’s original failure status while ensuring cleanup always runs.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 9a2f7296-9a93-433c-bf76-f0b0cc7be3c2
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (21)
.github/ISSUE_TEMPLATE/bug.yml.github/ISSUE_TEMPLATE/feature.yml.github/PULL_REQUEST_TEMPLATE.md.github/workflows/codeql.yml.github/workflows/osv-scanner.ymlCHANGELOG.mddesktop/src-tauri/Cargo.tomldesktop/src-tauri/client/Cargo.tomldesktop/src-tauri/database/Cargo.tomldesktop/src-tauri/download_manager/Cargo.tomldesktop/src-tauri/games/Cargo.tomldesktop/src-tauri/process/Cargo.tomldesktop/src-tauri/remote/Cargo.tomldesktop/src-tauri/tailscale/Cargo.tomlserver/composables/users.tsserver/package.jsonserver/plugins/error-handler.tsserver/server/internal/clients/event-handler.tssites/docs/package.jsonsites/promo/package.jsontorrential/src/downloads/download.rs
💤 Files with no reviewable changes (1)
- server/package.json
- Issue 1: Update @astrojs/starlight to ^0.41.0 for peer dep compatibility - Issue 2: Restore OSV-Scanner reusable workflow for diff-based PR gating - Issue 3: Add proper error handling and logging for JWT verification
- Add redaction warning to bug template logs textarea - Pin actions/checkout and osv-scanner-cli to commit SHAs - Change JWT_TIME_WIGGLE to seconds (jose expects seconds) - Use importX509 for X.509 certificates instead of importSPKI - Wrap typegen:sanity cleanup to always run rm
|




Summary
Batch remediation PR that resolves 12 open issues from the Hyperplan adversarial review and SonarCloud audit.
Changes
CI/Tooling
autobuildfor JS/TS and Rust (enables taint-tracking queries)Rust Safety
torrential/src/downloads/download.rs:107— now returns proper errorTypeScript/Prisma
@ts-expect-errorinusers.tsby aligning state type with API responseSites
content-collections buildtypegen script for sites/promoVerification
pnpm --filter drop typecheckpassespnpm --filter drop lintpasses (warnings only, no errors)pnpm --filter drop testpasses (157 tests)Closes
Closes #46, #47, #49, #50, #55, #56, #57, #58, #59, #62, #63
Summary by CodeRabbit