这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@SethFalco
Copy link
Member

@SethFalco SethFalco commented Oct 26, 2025

Fixed a crash when basics.image is defined. I wasn't using the correct message key in this case and did not test thoroughly enough.

Also amends the error message in the key a missing message key happens to specify which key so that it is quicker to debug in future.

Summary by CodeRabbit

  • Improvements
    • Enhanced error messages for translation debugging to include missing key information.
    • Improved Open Graph metadata for social media sharing of resume content.

@coderabbitai
Copy link

coderabbitai bot commented Oct 26, 2025

Walkthrough

Modified error messaging in the i18n module to display missing message keys, and updated a template meta tag key from "avatar" to "avatar-description" for more descriptive i18n alignment.

Changes

Cohort / File(s) Summary
i18n error messaging
src/i18n/messages.js
Enhanced error message when a message key is not found to include the missing key identifier for improved debugging
Resume template metadata
src/resume.handlebars
Changed Open Graph image alt text i18n key from "avatar" to "avatar-description" for better semantic alignment

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Both changes are simple key/string replacements with no logic modifications
  • No control flow or structural changes involved

Poem

🐰 A key was renamed, an error grew wise,
with messages now showing what went awry.
Small tweaks made clear what before was opaque,
i18n now sings with each change that we make! ✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title "fix: don't crash when basics.image is present" accurately describes the primary purpose of the pull request. The changes made in src/resume.handlebars directly address this issue by correcting the i18n key from "avatar" to "avatar-description", which prevents the crash that occurred when basics.image is defined and the old key was missing from the message catalog. The secondary change to the error message in src/i18n/messages.js is a supporting improvement that aids debugging. The title is concise, clear, and specific enough for a teammate to understand the main fix without ambiguity.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3d4c00d and 75a1c4f.

📒 Files selected for processing (2)
  • src/i18n/messages.js (1 hunks)
  • src/resume.handlebars (1 hunks)
🔇 Additional comments (2)
src/i18n/messages.js (1)

87-87: LGTM! Improved error message for debugging.

Including the missing key in the error message will significantly speed up debugging when encountering unknown i18n keys.

src/resume.handlebars (1)

29-29: The "avatar-description" key is properly defined in all locale files. Verification confirms the key exists in pl, en, nl, and bs locale files with appropriate values and {$name} placeholders. The code change correctly fixes the crash by using the existing key instead of the missing "avatar" key.


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.

@SethFalco SethFalco merged commit 6c7623d into jsonresume:main Oct 26, 2025
2 of 3 checks passed
@SethFalco SethFalco deleted the fix-image branch October 26, 2025 00:15
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