fix: avoid persisting invalid plugin upload artifacts - #739
Merged
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request refactors the plugin package management system by introducing a two-phase "Prepare" and "Persist" workflow, which enables robust rollback capabilities for assets, packages, and database records during upload failures. The changes also include the addition of miniredis and sqlite dependencies to support a new suite of integration tests for plugin and bundle uploads. Review feedback identifies a potential resource leak if the plugin decoder is not closed and points out a race condition in the rollback logic that could lead to data loss during concurrent uploads. Additionally, the reviewer suggests removing redundant identity checks in the service layer to simplify the code.
laipz8200
force-pushed
the
laipz8200/fix-plugin-upload-validation-cleanup
branch
from
May 16, 2026 15:07
5d4fca3 to
936a6cc
Compare
laipz8200
force-pushed
the
laipz8200/fix-plugin-upload-validation-cleanup
branch
from
May 16, 2026 15:15
936a6cc to
d248c12
Compare
laipz8200
marked this pull request as ready for review
May 16, 2026 15:32
41tair
approved these changes
May 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adjust plugin upload validation order so failed validations do not leave stale upload artifacts.
Keep bundle package uploads atomic when dependency validation fails.
Type of Change
Additional Information
No additional context.