Skip to content

Don't report a failed deploy-lock read as "unlock called when lock is not held" - #7257

Open
denik wants to merge 4 commits into
mainfrom
denik/locker-unlock-error
Open

denik wants to merge 4 commits into
mainfrom
denik/locker-unlock-error

Conversation

@denik

@denik denik commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Changes

Locker.Unlock re-reads the lock file to check that it still holds the lock. Only a missing lock file or one held by someone else is now reported as unlock called when lock is not held; any other read error becomes failed to check the deploy lock before releasing it: <err>.

Why

A read that timed out produced a misleading message (CI dashboard, bundle/invariant/delete_idempotent on Azure):

Error: unlock called when lock is not held: Get "[DATABRICKS_URL]/api/2.0/workspace/export": request timed out after 1m30s of inactivity

The lock was held; we just failed to read it.

Dashboard: test acceptance.TestAccept/bundle/invariant/delete_idempotent/DMS=/INPUT_CONFIG=feature.yml.tmpl/READPLAN=; error 3019.

# 3019 (azure)
LOG.deploy_initial: Error: unlock called when lock is not held: Get "[DATABRICKS_URL]/api/2.0/workspace/export": request timed out after 1m30s of inactivity

Tests

New unit tests in libs/locker for both cases; existing bundle/deploy/lock acceptance tests pass.

This pull request and its description were written by Isaac.

@eng-dev-ecosystem-bot

eng-dev-ecosystem-bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Collaborator

Integration test report

Commit: 8908e98

Run: 41446850501

Env ✅​pass 🙈​skip Time
✅​ aws linux-2core-8gb 281 15 4:01
✅​ aws-windows-latest-4core-16gb 283 13 3:39
✅​ azure linux-2core-8gb 280 15 4:08
✅​ azure-windows-latest-4core-16gb 282 13 3:34
✅​ gcp linux-2core-8gb 281 15 4:10
✅​ gcp-windows-latest-4core-16gb 283 13 3:37
Top 3 slowest tests (at least 2 minutes):
duration env testname
3:33 aws-windows-latest-4core-16gb TestAccept
3:30 gcp-windows-latest-4core-16gb TestAccept
3:28 azure-windows-latest-4core-16gb TestAccept

denik and others added 3 commits November 2, 2026 11:13
Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
@denik
denik force-pushed the denik/locker-unlock-error branch from c7cb288 to 121a882 Compare November 2, 2026 11:18
Co-authored-by: Isaac <no-reply@databricks.com>
@denik
denik marked this pull request as ready for review November 2, 2026 13:11
@denik
denik requested a review from a team as a code owner November 2, 2026 13:11
@denik
denik requested a review from shreyas-goenka November 2, 2026 13:11

This branch has not been deployed

No deployments
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