Skip to content

Added e2e for DeleteCommand returns 0 for SuccessCount and FailCount … - #3307

Closed
bhanurp wants to merge 10 commits into
jfrog:masterfrom
bhanurp:fix-failure-count-on-404
Closed

bhanurp wants to merge 10 commits into
jfrog:masterfrom
bhanurp:fix-failure-count-on-404

Conversation

@bhanurp

@bhanurp bhanurp commented Jan 9, 2026 •

Copy link
Copy Markdown
Contributor

…when errors occur

  • All tests have passed. If this feature is not already covered by the tests, new tests have been added.
  • The pull request is targeting the master branch.
  • The code has been validated to compile successfully by running go vet ./....
  • The code has been formatted properly using go fmt ./....

Description

This PR fixes a bug where DeleteCommand.Result().SuccessCount() and Result().FailCount() return 0 when 404 errors (or other errors) occur during deletion, even though some files may have been successfully deleted.

When using DeleteCommand and encountering errors (e.g., 404 errors when items are already deleted by another process), both SuccessCount() and FailCount() returned 0

solution

Changed to capture the deletion error separately and return actual counts regardless of whether an error occurred.

Depends On

jfrog/jfrog-cli-artifactory#342

@bhanurp bhanurp added bug Something isn't working safe to test Approve running integration tests on a pull request labels Jan 9, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 9, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 9, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 9, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 12, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 12, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 12, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 12, 2026
@bhanurp bhanurp added safe to test Approve running integration tests on a pull request and removed safe to test Approve running integration tests on a pull request labels Jan 12, 2026
Comment thread go.mod Outdated

// replace github.com/jfrog/jfrog-cli-artifactory => github.com/fluxxBot/jfrog-cli-artifactory v0.0.0-20260105073552-ae4f86048a11
//
replace github.com/jfrog/jfrog-cli-artifactory => github.com/bhanurp/jfrog-cli-artifactory v0.1.12-0.20260108075108-b5389ca4d380

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

placeholder to remove replace

@bhanurp bhanurp removed the safe to test Approve running integration tests on a pull request label Jan 13, 2026
@bhanurp bhanurp added the safe to test Approve running integration tests on a pull request label Jan 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

👍 Frogbot scanned this pull request and did not find any new security issues.


@bhanurp
bhanurp marked this pull request as ready for review January 13, 2026 00:20
@github-actions

Copy link
Copy Markdown
Contributor

This pull-request has been marked as stale due to 6 months of inactivity. As part of our effort to address every issue properly, please feel free to remove the stale label or keep this issue active by leaving a comment. Otherwise, it will be closed in 7 days

@github-actions github-actions Bot added the stale An outdated issue lacking engagement label Jul 12, 2026
@github-actions

Copy link
Copy Markdown
Contributor

This pull-request was closed due to 7 days of inactivity after being marked as stale. Feel free to reopen it if it remains relevant.

@github-actions github-actions Bot closed this Jul 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working safe to test Approve running integration tests on a pull request stale An outdated issue lacking engagement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant