Skip to content

fix: log errors in silent catch blocks - #383

Merged
LucasSantana-Dev merged 1 commit into
mainfrom
fix/silent-catch-blocks
Mar 30, 2026
Merged

LucasSantana-Dev merged 1 commit into
mainfrom
fix/silent-catch-blocks

Conversation

@LucasSantana-Dev

Copy link
Copy Markdown
Owner

Summary

Replace silent catch blocks with proper errorLog() calls in 7 files across bot and backend packages.

Changed Files

Bot package:

  • bot/start/initializer.ts — log client creation errors before throwing
  • download/utils/downloadAudio.ts — log stream destroy errors during cleanup
  • music/commands/recommendation/handlers/presetHandler.ts — log preset application errors
  • music/commands/recommendation/handlers/resetHandler.ts — log settings reset errors
  • music/commands/recommendation/handlers/settingsHandler.ts — log settings retrieval errors
  • music/commands/recommendation/handlers/updateHandler.ts — log settings update errors

Backend package:

  • services/GuildAutomationExecutionService.ts — log Discord API fetch errors

All catch blocks now use errorLog() with descriptive messages and error objects for better observability.

Test Plan

  • Build passes: npm run build --workspace=packages/bot
  • Build passes: npm run build --workspace=packages/backend
  • Backend tests pass: npm run test --workspace=packages/backend -- --testPathPatterns="GuildAutomation" --no-coverage
  • CI checks pass (SonarCloud, tests)

🤖 Generated with Claude Code

Replace silent catch blocks with errorLog calls across bot and
backend packages for better error observability.
@coderabbitai

coderabbitai Bot commented Mar 30, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@LucasSantana-Dev has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 3 minutes and 55 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 3 minutes and 55 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 64d25ec9-5828-4fae-9834-7afb1d9d9ada

📥 Commits

Reviewing files that changed from the base of the PR and between 53c6663 and 0a380db.

📒 Files selected for processing (8)
  • .agents/plans/lastfm-improvements-2026-03-30.md
  • packages/backend/src/services/GuildAutomationExecutionService.ts
  • packages/bot/src/bot/start/initializer.ts
  • packages/bot/src/functions/download/utils/downloadAudio.ts
  • packages/bot/src/functions/music/commands/recommendation/handlers/presetHandler.ts
  • packages/bot/src/functions/music/commands/recommendation/handlers/resetHandler.ts
  • packages/bot/src/functions/music/commands/recommendation/handlers/settingsHandler.ts
  • packages/bot/src/functions/music/commands/recommendation/handlers/updateHandler.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/silent-catch-blocks

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 and usage tips.

@vercel

vercel Bot commented Mar 30, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
lucky Ready Ready Preview, Comment Mar 30, 2026 7:43pm

Request Review

@sonarqubecloud

Copy link
Copy Markdown

@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@LucasSantana-Dev
LucasSantana-Dev merged commit 5aa96d8 into main Mar 30, 2026
11 of 12 checks passed
@LucasSantana-Dev
LucasSantana-Dev deleted the fix/silent-catch-blocks branch March 31, 2026 22:15

This branch was successfully deployed

1 active deployment
Preview — 0a380db3 Deployed Mar 30, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant