Skip to content

feat(client): report whether a binding waits for approval - #69

Open
tfelix wants to merge 1 commit into
mainfrom
feature/BD-2877_meshobject-binding-approval
Open

tfelix wants to merge 1 commit into
mainfrom
feature/BD-2877_meshobject-binding-approval

Conversation

@tfelix

@tfelix tfelix commented Nov 4, 2026

Copy link
Copy Markdown
Collaborator

🤖 Written by AI agent

With four-eyes approval on, meshStack now sends role bindings made through the meshObject API through approval (meshcloud/meshfed-release#11623). A binding can then be pending. This adds status.approval (ASSIGNED or PENDING) to user and group bindings, so the Terraform provider can warn while a binding waits for approval.

Older meshStacks do not send the field, so it stays nil.

🤖 Generated with Claude Code

Comment thread client/binding_approval.go Resolved
Comment thread client/binding_approval.go Resolved
Comment thread client/binding_status.go Resolved
Comment thread client/binding_approval.go Resolved

@grubmeshi grubmeshi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

yeah, just minor code remarks (please less pointeritis)

@tfelix
tfelix force-pushed the feature/BD-2877_meshobject-binding-approval branch from c5010fe to 8922a62 Compare November 6, 2026 10:23
With four-eyes approval on, meshStack keeps a binding created through the
API pending until a person approves it in meshPanel. Workspace and
project bindings now carry "status.approval", ASSIGNED or PENDING, so
the Terraform provider can tell its users. Group bindings get a status
for this.

BD-2877

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@tfelix
tfelix force-pushed the feature/BD-2877_meshobject-binding-approval branch from 8922a62 to cbdf0d6 Compare November 6, 2026 10:30
@sonarqubecloud

sonarqubecloud Bot commented Nov 6, 2026

Copy link
Copy Markdown

@meshcloud-gh-actions

Copy link
Copy Markdown

Coverage of the acceptance run against the meshStack backend, on cbdf0d6d013a559087bc15fd3c1449fe53506bf2.

Scope Coverage
Unit tests 78.2%
Acceptance tests 55.4%
Combined 80.9%
Uncovered functions
client/api_key.go:52: meshApiKeyClient.Create 0.0%
client/api_key.go:56: meshApiKeyClient.Read 0.0%
client/api_key.go:60: meshApiKeyClient.Update 0.0%
client/api_key.go:64: meshApiKeyClient.Delete 0.0%
client/api_key_permissions.go:20: ApiKeyPermissions.AllCodes 0.0%
client/api_key_permissions.go:33: ApiKeyPermissions.WorkspaceCodes 0.0%
client/api_key_permissions.go:262: AllApiKeyPermissions 0.0%
client/api_key_permissions.go:266: WorkspacePermissionCodes 0.0%
client/binding_status.go:18: *MeshGroupBindingStatus.WaitsForApproval 0.0%
client/binding_status.go:22: *MeshUserBindingStatus.WaitsForApproval 0.0%
client/building_block_definition.go:71: MeshBuildingBlockDefinitionApprovalPolicies.NothingRequiresApproval 0.0%
client/building_block_definition.go:82: DisabledSchedule 0.0%
client/building_block_definition.go:89: MeshBuildingBlockDefinitionSchedule.IsDisabled 0.0%
client/building_block_definition.go:93: MeshBuildingBlockDefinitionSpec.HasNeutralPolicies 0.0%
client/building_block_definition.go:97: MeshBuildingBlockDefinitionSpec.WithNeutralPolicies 0.0%
client/building_block_definition.go:166: meshBuildingBlockDefinitionClient.List 0.0%
client/building_block_definition.go:173: meshBuildingBlockDefinitionClient.Read 0.0%
client/building_block_definition.go:177: meshBuildingBlockDefinitionClient.Create 0.0%
client/building_block_definition.go:181: meshBuildingBlockDefinitionClient.Update 0.0%
client/building_block_definition.go:185: meshBuildingBlockDefinitionClient.Delete 0.0%
client/building_block_definition_version.go:101: MeshBuildingBlockType.TagInputTargets 0.0%
client/building_block_definition_version.go:245: meshBuildingBlockDefinitionVersionClient.Create 0.0%
client/building_block_definition_version.go:254: meshBuildingBlockDefinitionVersionClient.Update 0.0%
client/building_block_definition_version_implementation.go:81: MeshBuildingBlockDefinitionImplementation.InferType 0.0%
client/building_block_definition_version_implementation.go:95: MeshBuildingBlockDefinitionImplementation.MarshalJSONTo 0.0%
... and 129 more

covdata func names a method without its receiver, so an entry can belong to an implementation nothing selects rather than to a function the tests never reached. Open the file and line before reading one as a coverage gap.

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.

2 participants