Skip to content

Improve image upload cleanup logic, reduce e2e flake#2674

Merged
david-crespo merged 1 commit into
mainfrom
image-upload-e2e-fix
Feb 4, 2025
Merged

Improve image upload cleanup logic, reduce e2e flake#2674
david-crespo merged 1 commit into
mainfrom
image-upload-e2e-fix

Conversation

@david-crespo

@david-crespo david-crespo commented Feb 4, 2025

Copy link
Copy Markdown
Collaborator

Trying to fix some flakes that came up in #2671 (and periodically for a very long time). I think we were calling cleanup twice more often than I thought.

@vercel

vercel Bot commented Feb 4, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
console ✅ Ready (Inspect) Visit Preview Feb 4, 2025 8:55pm

await deleteDiskCleanup.mutateAsync({ path: { disk: disk.current.id } })
disk.current = null
}
cleaningUp.current = false

@david-crespo david-crespo Feb 4, 2025

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because we turned this back to false when cleanup was done, it did not prevent it from running twice in the case where the first attempt finished before the second started. Instead, we now prevent it from running twice by only calling it in one place.

@david-crespo david-crespo merged commit 5bd61e6 into main Feb 4, 2025
@david-crespo david-crespo deleted the image-upload-e2e-fix branch February 4, 2025 21:20
david-crespo added a commit to oxidecomputer/omicron that referenced this pull request Feb 6, 2025
oxidecomputer/console@288f1c1...517353e

* [517353ee](oxidecomputer/console@517353ee) bump vite and vitest (vitest CVE)
* [a6319fc8](oxidecomputer/console@a6319fc8) oxidecomputer/console#2671
* [5bd61e67](oxidecomputer/console@5bd61e67) oxidecomputer/console#2674
* [4646ad47](oxidecomputer/console@4646ad47) minor: console.log -> console.info in api-diff
* [7723212c](oxidecomputer/console@7723212c) log before and after file paths in api-diff
* [7cde843f](oxidecomputer/console@7cde843f) minor: deleted temp dir problem in bump-omicron.ts
david-crespo added a commit to oxidecomputer/omicron that referenced this pull request Feb 6, 2025
oxidecomputer/console@288f1c1...517353e

* [517353ee](oxidecomputer/console@517353ee)
bump vite and vitest (vitest CVE)
* [a6319fc8](oxidecomputer/console@a6319fc8)
oxidecomputer/console#2671
* [5bd61e67](oxidecomputer/console@5bd61e67)
oxidecomputer/console#2674
* [4646ad47](oxidecomputer/console@4646ad47)
minor: console.log -> console.info in api-diff
* [7723212c](oxidecomputer/console@7723212c)
log before and after file paths in api-diff
* [7cde843f](oxidecomputer/console@7cde843f)
minor: deleted temp dir problem in bump-omicron.ts
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