fix(boxes): Test Connection on existing-box edit form - #126
Merged
Conversation
The Test Connection button on the box edit screen was failing on existing boxes because the JS sent a non-existent `server_id` form field. The backend already supports a "look up by box_id, decrypt stored key" recovery path (haproxy_config.go:427-449) but never received the box_id needed to trigger it. Form field name `server_id` -> `box_id` to match the readonly input the edit form already renders, and the existing backend path takes over from there. No changes needed on the backend; this is purely the missing handshake the recovery code was waiting for. Phase 0 of the issue-72 plan; landed independently so the visible bug clears now and the multi-key rotation work that follows starts from a working Test Connection baseline. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes the Box edit form’s “Test Connection” path by sending the existing box_id to the backend so it can load and decrypt the stored API key server-side.
Changes:
- Updates the Test Connection form payload from
server_idtobox_id. - Adds an inline comment explaining why edit-mode connection tests need
box_id.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
server_idform field. The backend already supports a "look up bybox_id, decrypt the stored key, run probe server-side" recovery path athaproxy_config.go:427-449— it just never received thebox_idneeded to trigger it.server_id→box_id) and read from the existing readonlybox_idinput that the edit form already renders. No backend changes needed.Test plan
make templ-generate && make buildclean.Related
🤖 Generated with Claude Code