Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

materialize-boilerplate: fix staged files cleanup again #2455

Merged
merged 1 commit into from
Feb 27, 2025

Conversation

williamhbaker
Copy link
Member

@williamhbaker williamhbaker commented Feb 26, 2025

Description:

In f4a82c4 a partial fix was implemented to prevent attempts to cleanup the same files again when a binding had data for one but not a subsequent transaction.

That change fixed that issue, but it also made it so that staged files just never got cleaned up, because f.started is set to false by f.flush(), which is always called before the cleanup.

A complete fix is here, which clears out the list of uploaded files after sending them off for deletion.

Workflow steps:

(How does one use this feature, and how has it changed)

Documentation links affected:

(list any documentation links that you created, or existing ones that you've identified as needing updates, along with a brief description)

Notes for reviewers:

(anything that might help someone review this PR)


This change is Reviewable

In f4a82c4 a partial fix was implemented to prevent attempts to cleanup the same
files again when a binding had data for one but not a subsequent transaction.

That change fixed that issue, but it also made it so that staged files just
never got cleaned up, because `f.started` is set to `false` by `f.flush()`,
which is always called before the cleanup.

A complete fix is here, which clears out the list of uploaded files after
sending them off for deletion.
Copy link
Member

@Alex-Bair Alex-Bair left a comment

Choose a reason for hiding this comment

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

LGTM

@williamhbaker williamhbaker merged commit 4c6ae3c into main Feb 27, 2025
54 of 56 checks passed
@williamhbaker williamhbaker deleted the wb/staged-files-cleanup branch February 27, 2025 13:27
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