Skip to content

Reproduce stale-published-content dashboard bug as acceptance test#5597

Open
denik wants to merge 11 commits into
mainfrom
denik/dashboard-published-bug
Open

Reproduce stale-published-content dashboard bug as acceptance test#5597
denik wants to merge 11 commits into
mainfrom
denik/dashboard-published-bug

Conversation

@denik

@denik denik commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

Adds an acceptance test for the bug where a dashboard rename succeeds (PATCH) but the subsequent publish fails, leaving the user unable to recover by simply re-running deploy.

What the test shows:

  1. First deploy: dashboard created and published as "my dashboard"
  2. Second deploy (fault injected on POST /published): PATCH renames the draft to "my dashboard renamed" and bumps the remote etag, but publish fails. SaveState is only called on success, so state retains the pre-PATCH etag.
  3. Third deploy: detects state.etag ≠ remote.etag and errors with "dashboard has been modified remotely" — no API writes are attempted, so the stale published version ("my dashboard") is never updated.

Also includes:

  • testserver: bump dashboard etag on every PATCH (previously only bumped when SerializedDashboard changed), matching actual cloud behavior
  • Dashboard acceptance tests: replace generic ETAG regex replacements in test.toml with per-test add_repl.py calls so etag value changes are visible in diffs

denik added 5 commits June 14, 2026 08:32
Co-authored-by: Denis Bilenko <denis.bilenko@databricks.com>
… calls

Co-authored-by: Denis Bilenko <denis.bilenko@databricks.com>
Previously the fake workspace only bumped the etag when SerializedDashboard
changed. Cloud bumps it on every write. Update the test server and regenerate
the stale-content acceptance test output accordingly.

Co-authored-by: Isaac
SaveState is only called on success; the failing second deploy leaves state
with the pre-PATCH etag. The third deploy detects the etag mismatch and
errors with "modified remotely" instead of silently skipping publish.
Wrap the third deploy in errcode so the subsequent get/get-published calls
run and show the draft renamed while the published version is still stale.

Co-authored-by: Isaac
@github-actions

github-actions Bot commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

Approval status: pending

/acceptance/bundle/ - needs approval

22 files changed
Suggested: @shreyas-goenka
Also eligible: @pietern, @andrewnester, @lennartkats-db, @anton-107, @janniklasrose

General files (require maintainer)

Files: libs/testserver/dashboards.go
Based on git history:

  • @shreyas-goenka -- recent work in libs/testserver/, acceptance/bundle/resources/dashboards/simple/, acceptance/bundle/resources/dashboards/detect-change/

Any maintainer (@andrewnester, @anton-107, @pietern, @shreyas-goenka, @simonfaltum, @renaudhartert-db) can approve all areas.
See OWNERS for ownership rules.

@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:02 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:02 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:12 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:12 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:14 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:14 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:18 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:18 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:21 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:21 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:31 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:31 — with GitHub Actions Inactive
@denik denik temporarily deployed to test-trigger-is June 14, 2026 16:37 — with GitHub Actions Inactive
@denik denik deployed to test-trigger-is June 14, 2026 16:37 — with GitHub Actions Active
@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

Integration test report

Commit: d0c4fc6

Run: 27505300945

Env 🟨​KNOWN 💚​RECOVERED 🙈​SKIP ✅​pass 🙈​skip Time
🟨​ aws linux 7 15 264 978 8:01
🟨​ aws windows 7 15 266 976 15:44
💚​ aws-ucws linux 7 15 360 892 7:41
💚​ aws-ucws windows 7 15 362 890 12:21
💚​ azure linux 1 17 267 976 6:27
💚​ azure windows 1 17 269 974 11:09
💚​ azure-ucws linux 1 17 365 888 8:28
💚​ azure-ucws windows 1 17 367 886 13:23
💚​ gcp linux 1 17 263 979 7:50
💚​ gcp windows 1 17 265 977 12:23
22 interesting tests: 15 SKIP, 7 KNOWN
Test Name aws linux aws windows aws-ucws linux aws-ucws windows azure linux azure windows azure-ucws linux azure-ucws windows gcp linux gcp windows
🟨​ TestAccept 🟨​K 🟨​K 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R
🙈​ TestAccept/bundle/invariant/no_drift 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/permissions 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions 🟨​K 🟨​K 💚​R 💚​R 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/DATABRICKS_BUNDLE_ENGINE=direct 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/with_permissions/DATABRICKS_BUNDLE_ENGINE=terraform 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions 🟨​K 🟨​K 💚​R 💚​R 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/DATABRICKS_BUNDLE_ENGINE=direct 🟨​K 🟨​K 💚​R 💚​R
🟨​ TestAccept/bundle/resources/permissions/jobs/destroy_without_mgmtperms/without_permissions/DATABRICKS_BUNDLE_ENGINE=terraform 🟨​K 🟨​K 💚​R 💚​R
🙈​ TestAccept/bundle/resources/postgres_branches/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/recreate 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/replace_existing 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/update_protected 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_branches/without_branch_id 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_endpoints/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_endpoints/recreate 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/postgres_projects/update_display_name 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/synced_database_tables/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_endpoints/drift/recreated_same_name 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_indexes/basic 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/bundle/resources/vector_search_indexes/grants/select 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
🙈​ TestAccept/ssh/connection 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S 🙈​S
Top 28 slowest tests (at least 2 minutes):
duration env testname
7:51 azure-ucws windows TestAccept
6:17 gcp windows TestAccept
6:13 aws-ucws windows TestAccept
6:02 azure windows TestAccept
4:31 gcp windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
4:20 gcp windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
4:14 gcp linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
4:00 gcp linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:24 aws-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:16 aws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:15 aws-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
3:11 aws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:11 azure windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:08 aws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
3:06 azure-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
3:01 aws-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
3:01 azure linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:58 gcp linux TestAccept
2:54 azure linux TestAccept
2:54 aws-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:54 aws-ucws linux TestAccept
2:50 azure-ucws linux TestAccept
2:48 azure-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=terraform
2:39 azure-ucws linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:35 azure-ucws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:34 azure windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:26 azure linux TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct
2:25 aws windows TestAccept/bundle/resources/apps/inline_config/DATABRICKS_BUNDLE_ENGINE=direct

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