Skip to content

sandbox: rename lakeboxsandbox across CLI surface#5487

Merged
akshaysingla-db merged 1 commit into
databricks:demo-lakeboxfrom
akshaysingla-db:akshay/lakebox-to-sandbox-rename
Jun 9, 2026
Merged

sandbox: rename lakeboxsandbox across CLI surface#5487
akshaysingla-db merged 1 commit into
databricks:demo-lakeboxfrom
akshaysingla-db:akshay/lakebox-to-sandbox-rename

Conversation

@akshaysingla-db

Copy link
Copy Markdown
Contributor

Summary

User-visible rename. The command is now databricks sandbox … instead of databricks lakebox …. Internals follow the same naming: Go package, directory, identifiers, state file, SSH key file, SSH config alias, and managed include file all switch from lakebox to sandbox.

The wire-format API path is the one exceptionsandboxAPIPath and sandboxKeysAPIPath still point at /api/2.0/lakebox/... because the server-side rename is happening separately. A comment on the const block in api.go flags this as the sole intentional lakebox string in the codebase.

What changed

Layer Before After
CLI command databricks lakebox … databricks sandbox …
Go package + directory cmd/lakebox/ (25 files) cmd/sandbox/
Identifiers lakeboxAPI, newLakeboxAPI, lakeboxKeyPath, etc. sandboxAPI, newSandboxAPI, sandboxKeyPath, etc.
State file ~/.databricks/lakebox.json ~/.databricks/sandbox.json
SSH key ~/.ssh/lakebox_ed25519 ~/.ssh/sandbox_ed25519
Managed include ~/.ssh/databricks-lakebox ~/.ssh/databricks-sandbox
SSH config alias Host lakebox-gw Host sandbox-gw
Include-block markers # >>> databricks lakebox >>> # >>> databricks sandbox >>>
Acceptance dir acceptance/cmd/lakebox/ (20 scenarios) acceptance/cmd/sandbox/
API path values /api/2.0/lakebox/sandboxes and /api/2.0/lakebox/ssh-keys unchanged — server rename pending

cmd/cmd.go import + AddCommand updated; cmd/fuzz_panic_test.go manual-roots skip-list updated. Workspace UI needs a matching update to the SSH alias (lakebox-gwsandbox-gw) so the "First time setup?" disclosure and the editor deep-links stay in sync — flagging for the UI side.

Migration impact

Existing CLI users (snapshot installs from internal/bugbash/install.sh) will need to re-register on first use after the upgrade — old key, state, and SSH-config entries are orphaned under the lakebox names. Low risk because we haven't shipped publicly yet.

Test plan

  • go test ./cmd/sandbox/... passes (22 unit tests)
  • go test ./acceptance -run TestAccept/cmd/sandbox passes (20 acceptance tests, all goldens regenerated)
  • go test ./cmd/... passes overall (no other suite indexed the lakebox name)
  • go build ./... clean
  • ./task lint clean
  • grep -rE '\blakebox\b' outside internal/bugbash/ returns only the intentional /api/2.0/lakebox API-path values

This pull request and its description were written by Isaac.

@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Waiting for approval

Based on git history, these people are best suited to review:

  • @shuochen0311 -- recent work in cmd/lakebox/
  • @pietern -- recent work in cmd/, cmd/lakebox/

Eligible reviewers: @andrewnester, @anton-107, @denik, @renaudhartert-db, @shreyas-goenka, @simonfaltum

Suggestions based on git history. See OWNERS for ownership rules.

@akshaysingla-db
akshaysingla-db force-pushed the akshay/lakebox-to-sandbox-rename branch from 282154a to 04ebdf2 Compare June 9, 2026 19:14
User-visible rename. The command is now `databricks sandbox …` instead
of `databricks lakebox …`. Internals follow the same naming: Go
package, directory, identifiers, state file, SSH key file, SSH config
alias, and managed include file all switch from "lakebox" to "sandbox".

The wire-format API path is the one exception — `sandboxAPIPath` and
`sandboxKeysAPIPath` still point at `/api/2.0/lakebox/...` because the
server-side rename is happening separately. A comment on the const
block flags this as the sole intentional "lakebox" string in the
codebase.

Specifically renamed:

- `cmd/lakebox/` → `cmd/sandbox/` (Go package + 25 files, identifiers
  like `lakeboxAPI` → `sandboxAPI`, `lakeboxKeyPath` → `sandboxKeyPath`,
  `newLakeboxAPI` → `newSandboxAPI`, etc.)
- `acceptance/cmd/lakebox/` → `acceptance/cmd/sandbox/` (20 test
  scenarios, scripts say `$CLI sandbox …`, server stubs still match
  `/api/2.0/lakebox/...`)
- `~/.databricks/lakebox.json` → `~/.databricks/sandbox.json` (state)
- `~/.ssh/lakebox_ed25519` → `~/.ssh/sandbox_ed25519` (key)
- `~/.ssh/databricks-lakebox` → `~/.ssh/databricks-sandbox` (managed
  include file)
- `Host lakebox-gw` → `Host sandbox-gw` (SSH config alias). Workspace
  UI needs to be updated to match.
- `# >>> databricks lakebox >>>` / `# <<< databricks lakebox <<<` →
  `databricks sandbox` markers in the include block.

Existing CLI users (snapshot installs from internal/bugbash/install.sh)
will need to re-register on first use after the upgrade — old key,
state, and SSH-config entries are orphaned under the lakebox names.
Low risk because we haven't shipped publicly yet.

cmd/cmd.go import + AddCommand updated; cmd/fuzz_panic_test.go
manual-roots skip-list updated.

Co-authored-by: Isaac
@akshaysingla-db
akshaysingla-db force-pushed the akshay/lakebox-to-sandbox-rename branch from 04ebdf2 to 6aaf271 Compare June 9, 2026 19:17
@akshaysingla-db
akshaysingla-db merged commit dc588c1 into databricks:demo-lakebox Jun 9, 2026
13 of 20 checks passed
akshaysingla-db added a commit to akshaysingla-db/cli that referenced this pull request Jun 9, 2026
The lakebox → sandbox rename PR (databricks#5487) did a bulk sed that
incorrectly rewrote 14 documentation comments naming the actual HTTP
endpoints. The wire path is `/api/2.0/lakebox/...` (server-side rename
pending — see the sandboxAPIRoot constant), but the docstrings on
list/get/create/update/delete/start/stop/registerKey/listKeys/
deleteKey/listResponse/registerKeyRequest were left saying
`/api/2.0/sandbox/...`, misleading any reader who treats the comment
as canonical.

Also restores the keyhash_test.go header comment that mentions where
the algorithm was verified.

Behavior unchanged; comments now match the actual `Pattern` strings
in the acceptance tests and the live URLs the CLI sends.

Co-authored-by: Isaac
akshaysingla-db added a commit that referenced this pull request Jun 9, 2026
## Summary

Follow-up to #5487. The bulk sed in that PR incorrectly rewrote 14
documentation comments that name the actual HTTP endpoints — the wire
path is `/api/2.0/lakebox/...` (server-side rename pending; see the
`sandboxAPIRoot` const), but the doc comments on `list` / `get` /
`create` / `update` / `delete` / `start` / `stop` / `registerKey` /
`listKeys` / `deleteKey` / `listResponse` / `registerKeyRequest` were
left saying `/api/2.0/sandbox/...`.

That mismatch is misleading — any reader treating the comment as
canonical would look for a non-existent endpoint. Restoring all 14 to
the actual wire path. Also restores the `keyhash_test.go` header comment
that documents where the algorithm was verified.

Behavior unchanged; comments now match the `[[Server]] Pattern` strings
in the acceptance tests and the URLs the CLI actually sends.

## Test plan

- [x] `go test ./cmd/sandbox/...` passes
- [x] `go build ./...` clean

## Note

This is stacked on #5487 (`lakebox` → `sandbox` rename). Until that
merges, the diff here shows the rename + the doc-comment fix together.
After #5487 lands on `demo-lakebox`, this PR's diff collapses to just
the 14 doc-comment line edits.

This pull request and its description were written by Isaac.
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.

1 participant