Skip to content

fix(kymabinding): surface BTP error bodies on Describe + Delete#735

Open
maximilianbraun wants to merge 4 commits into
mainfrom
fix/kymabinding-surface-btp-error-bodies
Open

fix(kymabinding): surface BTP error bodies on Describe + Delete#735
maximilianbraun wants to merge 4 commits into
mainfrom
fix/kymabinding-surface-btp-error-bodies

Conversation

@maximilianbraun

Copy link
Copy Markdown
Member

Summary

  • DescribeInstance and DeleteInstances in internal/clients/kymaenvironmentbinding/binding.go now route their API errors through the existing package-level specifyAPIError helper (already used by CreateInstance). Previously the bare transport error was wrapped, so the structured ApiExceptionResponseObject body never reached the resource's Synced condition.
  • The deliberate 404 swallow in DeleteInstances is preserved (covered by a regression test).
  • Fixes a pre-existing copy/paste bug where DescribeInstance's wrap message was errKymaBindingCreateFailed; introduces errKymaBindingDescribeFailed.
  • Adds unit tests mirroring the subaccount DeleteAPI5xxWrappedWithSpecifyAPIError pattern (PR fix(subaccount): surface BTP error bodies on delete via Synced condition #716).

Part of the BTP error-body fan-out series.

Test plan

  • go build ./...
  • go vet ./...
  • go test -race -count=1 ./internal/clients/kymaenvironmentbinding/...
  • go test -race -count=1 ./... — full suite green
  • gofmt -l internal/clients/kymaenvironmentbinding/ clean

DescribeInstance and DeleteInstances now route the API error through the
existing specifyAPIError helper so the structured BTP error body lands in
the resource's Synced condition instead of an opaque transport error.

The deliberate 404 swallow in DeleteInstances is preserved.
@maximilianbraun maximilianbraun added the release-notes/bugfix Marks PR as bugfix for release note generation label Jun 20, 2026

@maximilianbraun maximilianbraun left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Lean. No over-engineering findings.

@maximilianbraun maximilianbraun marked this pull request as draft June 20, 2026 08:19
@maximilianbraun maximilianbraun marked this pull request as ready for review June 20, 2026 08:47
@jn-av jn-av temporarily deployed to pr-e2e-approval June 23, 2026 15:44 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av had a problem deploying to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Failure
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av had a problem deploying to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Failure
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
@jn-av jn-av temporarily deployed to pr-e2e-no-approval June 23, 2026 15:47 — with GitHub Actions Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-notes/bugfix Marks PR as bugfix for release note generation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants