Fix test failures after jettison library update#61
Conversation
WalkthroughThe pull request introduces error context codes across the codebase using the jettison library's context parameter ( Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes The changes exhibit moderate complexity with mixed patterns: repetitive error context code additions ( Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (6)
🔇 Additional comments (13)
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. Comment |
Add error codes to sentinel errors for proper matching with errors.Is(). Update test expectations to use sentinel errors with codes instead of creating new error instances inline. Co-authored-by: dasco144 <10575019+dasco144@users.noreply.github.com>
4371be5 to
9a4b652
Compare
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
a95ac81 to
56faa88
Compare
9ad917d to
d7231e5
Compare
bfd66ce to
82331fa
Compare
|
@copilot can you rebase and fix the merge conflicts from main |
I've successfully rebased the branch onto
However, I'm unable to force-push the rebased history using the available tools due to a technical limitation. The local branch is ready with commits:
The branch needs to be force-pushed to update the remote. Could you either:
|
|
@copilot can you merge main into this branch then so you don't have to force push |
Done! I've merged |
filterErranddeserializationErrso they can be matched witherrors.Is()after wrappingmetadataEventFilterErrfor consistencySummary
Fixed test failures after jettison library update and merged with latest main.
Changes Made:
Added error codes to sentinel errors for proper
errors.Is()matching:filterErrinerrors.go- codeERR_d5e8f7a9b2c3d4e5deserializationErrinfilters/metadata.go- codeERR_a1b2c3d4e5f6a7b8metadataEventFilterErrinfilters/metadata.go- codeERR_c1f2e3d4a5b6c7d8ErrInvalidBatchConfiginrpatterns/batch.go- codeERR_invalid_batch_configUpdated error wrapping functions to include error codes:
asFilterErr()inerrors.goasDeserializationErr()andmakeMetadataEventFilterErr()infilters/metadata.goUpdated test expectations:
falsemetadata_test.goMerged with latest:
renovate/github.com-luno-jettison-digestbranch into this branchAll tests pass with no security vulnerabilities.
Original prompt
Fixes #60
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.
Summary by CodeRabbit
New Features
Chores