Skip to content

Conversation

@bhanurp
Copy link
Contributor

@bhanurp bhanurp commented Jan 9, 2026

…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
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
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
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
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant