Skip to content

fix(registry): guard against nil logger in RelationshipCSVHelper - #1086

Open
Omkar-Ugal wants to merge 2 commits into
meshery:masterfrom
Omkar-Ugal:fix/relationshipcsvhelper-nil-log
Open

fix(registry): guard against nil logger in RelationshipCSVHelper#1086
Omkar-Ugal wants to merge 2 commits into
meshery:masterfrom
Omkar-Ugal:fix/relationshipcsvhelper-nil-log

Conversation

@Omkar-Ugal

@Omkar-Ugal Omkar-Ugal commented Aug 7, 2026

Copy link
Copy Markdown
Member

Description
This fixes a nil pointer panic in RelationshipCSVHelper.ParseRelationshipsSheet() when Log is not initialized.

Signed commits

  • Yes, I signed my commits.

Summary by CodeRabbit

Bug Fixes

  • Improved relationship parsing when optional logging is unavailable.
  • Parsing errors are now returned consistently with clearer CSV row context.
  • Reduced unnecessary logging during relationship processing.

Signed-off-by: Omkar Ugalmugle <omkarugalmugle285@gmail.com>
@welcome

welcome Bot commented Aug 7, 2026

Copy link
Copy Markdown

Yay, your first pull request! 👍 A contributor will be by to give feedback soon. In the meantime, you can find updates in the #github-notifications channel in the community Slack.
Be sure to double-check that you have signed your commits. Here are instructions for making signing an implicit activity while performing a commit.

@coderabbitai

coderabbitai Bot commented Aug 7, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: bedd9c57-2544-42ce-8ac3-3f845875e398

📥 Commits

Reviewing files that changed from the base of the PR and between 88aa8c9 and f251e5b.

📒 Files selected for processing (1)
  • registry/relationship.go

Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review.


📝 Walkthrough

Walkthrough

Relationship parsing now guards informational logging against a nil logger. Errors from the error channel are wrapped with csv.ErrReadCSVRow and returned.

Changes

Relationship parsing

Layer / File(s) Summary
Guard relationship parsing logs
registry/relationship.go
The parser logs informational messages only when Log is initialized. It wraps relationship parsing errors with csv.ErrReadCSVRow and returns them.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to f251e

This is a localized fix for a nil logger panic in relationship parsing, with no actionable merge-blocking risk remaining beyond normal checks and review.

Suggested reviewers: codeahmedjamil

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the primary change: preventing a nil logger panic in RelationshipCSVHelper. It is concise and related to the pull request objectives.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
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 functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

Signed-off-by: Omkar Ugalmugle <omkarugalmugle285@gmail.com>
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