Skip to content

In retryablehttp client CheckRetry method, return err object when we … - #421

Merged
pshanbhag merged 1 commit into
masterfrom
private/pshanbhag/PCD-3055
Aug 20, 2025
Merged

pshanbhag merged 1 commit into
masterfrom
private/pshanbhag/PCD-3055

Conversation

@pshanbhag

@pshanbhag pshanbhag commented Aug 19, 2025 •

Copy link
Copy Markdown
Collaborator

…don't want to retry

In the current implementation, the error from the HTTP client is gobbled up when a retryablehttp client is used. Changing it to have the CheckRetry implementation used by pf9ctl to return any error the request receieved and retry was not needed.

Fixes: PCD-3055

Summary by Bito

This PR enhances documentation by improving inline comment spacing in cmd/detachNode.go for better clarity. It also strengthens error handling in pkg/util/helper.go by returning actual error objects instead of nils, ensuring proper error propagation throughout the codebase.

…don't want to retry

In the current implementation, the error from the HTTP client is gobbled up when
a retryablehttp client is used. Changing it to have the CheckRetry implementation
used by pf9ctl to return any error the request receieved and retry was not needed.

Fixes: PCD-3055
@pshanbhag
pshanbhag requested a review from tanaypf9 August 19, 2025 21:52
@bito-code-review

bito-code-review Bot commented Aug 19, 2025 •

Copy link
Copy Markdown
Contributor

Code Review Agent Run #32c6c9

Actionable Suggestions - 0
Review Details
  • Files reviewed - 2 · Commit Range: 8b03222..8b03222
    • cmd/detachNode.go
    • pkg/util/helper.go
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful
    • Golangci-lint (Linter) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Default Agent You can customize the agent settings here or contact your Bito workspace admin at mithil@platform9.com.

Documentation & Help

AI Code Review powered by Bito Logo

@pshanbhag
pshanbhag requested review from mithilarun and snslk August 19, 2025 21:53
@bito-code-review

Copy link
Copy Markdown
Contributor

Changelist by Bito

This pull request implements the following key changes.

Key Change Files Impacted
Documentation - Improved Comment Formatting

- detachNode.go - Refined inline comment spacing for clarity and consistency in node-related functions.

Bug Fix - Proper Error Propagation

- helper.go - Modified error return values to propagate actual errors instead of swallowing them during URL and TLS error checks.

@pshanbhag
pshanbhag merged commit fb1b1b4 into master Aug 20, 2025
@pshanbhag
pshanbhag deleted the private/pshanbhag/PCD-3055 branch August 20, 2025 04:34
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.

3 participants