lakebox: add ssh-key list/delete, default register --name, fix list null body#5290
Merged
akshaysingla-db merged 1 commit intoMay 20, 2026
Conversation
Contributor
Waiting for approvalBased on git history, these people are best suited to review:
Eligible reviewers: Suggestions based on git history. See OWNERS for ownership rules. |
…ull body Three related ssh-key UX changes plus a wire-format bug in `list`: 1. `ssh-key list` (new subcommand): GET /api/2.0/lakebox/ssh-keys. Renders the user's registered keys with a `*` gutter marker on the key matching this machine (using the existing keyHash helper from bd72f85). `--json` for scripting. 2. `ssh-key delete <key-hash>` (new subcommand): DELETE /api/2.0/lakebox/ssh-keys/{key_hash}. 3. `register --name` (new flag): defaults to this machine's hostname when not provided so `ssh-key list` is meaningful across multiple machines. Previously every locally-registered key landed with an empty name and surfaced as `(unset)`. 4. Fix `lakebox list` against any workspace that actually has lakebox deployed. Pieter's SDK ApiClient rewrite (08a56be) wrote the pagination call as `Do(..., headers, query, nil, &resp)` — but the SDK's makeRequestBody treats slot 6 (`request`) as the GET query string and slot 5 (`queryParams`) as ignored on GET. Routing the query through slot 5 with a nil body in slot 6 makes the SDK serialize nil as the literal JSON `null`, sent as the request body on a GET, which the lakebox manager rejects with `INVALID_PARAMETER_VALUE: Request body must be a JSON object`. Swap the args. Co-authored-by: Isaac
ef0be84 to
e474b84
Compare
9439c8a
into
databricks:demo-lakebox
13 of 19 checks passed
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.
Three related ssh-key UX changes plus a wire-format bug in
list:ssh-key list(new subcommand): GET /api/2.0/lakebox/ssh-keys. Renders the user's registered keys with a*gutter marker on the key matching this machine (using the existing keyHash helper from bd72f85).--jsonfor scripting.ssh-key delete <key-hash>(new subcommand): DELETE /api/2.0/lakebox/ssh-keys/{key_hash}.register --name(new flag): defaults to this machine's hostname when not provided sossh-key listis meaningful across multiple machines. Previously every locally-registered key landed with an empty name and surfaced as(unset).Fix
lakebox listagainst any workspace that actually has lakebox deployed. Pieter's SDK ApiClient rewrite (08a56be) wrote the pagination call asDo(..., headers, query, nil, &resp)— but the SDK's makeRequestBody treats slot 6 (request) as the GET query string and slot 5 (queryParams) as ignored on GET. Routing the query through slot 5 with a nil body in slot 6 makes the SDK serialize nil as the literal JSONnull, sent as the request body on a GET, which the lakebox manager rejects withINVALID_PARAMETER_VALUE: Request body must be a JSON object. Swap the args.Co-authored-by: Isaac
Changes
Why
Tests
Tested against
dbsql-dev-testing-default(workspace with lakebox deployed but no sandboxes):lakebox listreturns200 OKwith no body, prints "No lakeboxes found." (previously 400'd)lakebox ssh-key listrenders both keys with correct column alignment;*gutter marks the local keylakebox ssh-key list --jsonround-trips throughjqlakebox ssh-key delete <hash>— not yet exercised end-to-endlakebox register --name laptopagainst a clean workspace — confirm name lands