improvement logging and create patch release - #285
Conversation
Signed-off-by: Arrobo, Gabriel <gabriel.arrobo@intel.com>
There was a problem hiding this comment.
🟢 Ready to approve
The changes are small and low-risk (version bump + clearer error strings + context-variable cleanup), with only minor best-practice nits noted.
This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.
Pull request overview
This PR finalizes a patch release by removing the -dev suffix from the project version and improves MongoDB API error logging context while avoiding context package shadowing in WithContext helpers.
Changes:
- Promote
VERSIONfrom1.8.4-devto1.8.4for the patch release. - Improve MongoDB API error messages to include the specific
WithContextmethod and underlying driver operation (e.g.,UpdateOne,DeleteOne,InsertMany). - Rename
WithContextparameters fromcontexttoctxto avoid shadowing thecontextpackage and pass the correct context variable into driver calls.
File summaries
| File | Description |
|---|---|
| VERSION | Updates version string for the patch release. |
| mongoapi/mongoapi.go | Improves error-message clarity and avoids context identifier shadowing in context-aware MongoDB helpers. |
Review details
Suppressed comments (3)
mongoapi/mongoapi.go:212
- Use %w instead of %+v to wrap the underlying MongoDB error so callers can use errors.Is/errors.As while still preserving the message context.
return fmt.Errorf("RestfulAPIDeleteOneWithContext DeleteOne err: %+v", err)
mongoapi/mongoapi.go:158
- Use %w instead of %+v to wrap the underlying MongoDB error so callers can use errors.Is/errors.As while still preserving the message context.
return fmt.Errorf("RestfulAPIPullOneWithContext UpdateOne err: %+v", err)
mongoapi/mongoapi.go:346
- Use %w instead of %+v to wrap the underlying MongoDB error so callers can use errors.Is/errors.As while still preserving the message context.
return fmt.Errorf("RestfulAPIPostManyWithContext InsertMany err: %+v", err)
- Files reviewed: 2/2 changed files
- Comments generated: 1
- Review effort level: Lite
We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.
Signed-off-by: Arrobo, Gabriel <gabriel.arrobo@intel.com>
There was a problem hiding this comment.
🟢 Ready to approve
The changes are small, consistent, and improve error propagation without altering functional behavior.
This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 0 new
- Review effort level: Lite
We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.
No description provided.