Repository navigation
fix(ui): make the confirm step match the job - #96
Merged
Merged
Conversation
Only rows that plan a write take a file name, and the confirmation carries that decision to the job. Turning the XML on brings back a row only the XML could carry. The preview says what an export in place would refuse, writing nothing. One plan runs at a time, and Write waits for it. The analysed event carries the export's stale flag. The same-name skip has wording true to each case. Signed-off-by: Ilham Deneri <ilhamdeneri@gmail.com>
Move the analysed event's handling into its own method, since the flag took the function over the line limit. Document the change in the product and architecture docs. A batch whose first row writes nothing now writes the row it used to skip, and the grid report's note on a same-name skip has new words. No audio, grid or number changes. Output-Change: yes Signed-off-by: Ilham Deneri <ilhamdeneri@gmail.com>
The test locks a file with chflags, which Linux doesn't have, so it failed there before it could check anything. Signed-off-by: Ilham Deneri <ilhamdeneri@gmail.com>
A row an export in place would refuse never enters the job, so the table showed its plan once the summary closed. Mark it failed with its refusal, as a failed export would be. A skipped row could read "Exported without the rekordbox XML" in place of its skip reason, though it was never exported; it keeps the reason now. The stale line says the grid or the file changed, since a changed source makes the export stale too. Add a test that a client sending sameName false for two rows of one name overwrites nothing: the folder check, the transaction and the no-replace rename each refuse it. Signed-off-by: Ilham Deneri <ilhamdeneri@gmail.com>
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.
Summary
Six small fixes so that what the export confirm step says is what the job does. Only rows that plan a write take a file name, and the confirmation carries that decision to the job instead of the job recomputing it. Turning the XML on brings back a row only the XML could carry. The preview runs the in-place refusals, writing nothing. One plan runs at a time. The
analysedevent carriesexportStale. The same-name skip has wording true to each case, with what to do.User-visible behaviour
A/track.wavfirst in the list no longer skipsB/track.wav;Bis written.nothingToWritecomes back, and Export no longer says "Nothing new to export".busy.IPC:
ConfirmedFile.sameName,JobEvent::Analysed.exportStaleand the skip reasonsameNameInBatchare new; bindings regenerated. No persisted schema changed.Tests run
1127 Rust and 404 frontend tests pass. Each fix was broken on purpose and a test failed, then it was restored:
regression_a_row_that_stays_a_skip_takes_no_nameregression_a_row_that_cannot_be_planned_takes_no_nameregression_a_row_the_confirm_skipped_stays_skipped_when_the_name_taker_drops_outcarries the plan's same-name decision, row by row, ...xmlnot comparedcomes back when the XML is turned onregression_the_plan_says_what_an_export_in_place_would_refuse_and_changes_nothing,a_locked_file_is_refused_in_the_planregression_the_plan_says_what_an_export_in_place_would_refuse_and_changes_nothing(recursive tree compare)one plan at a timeregression_the_analysed_event_says_what_the_session_says_of_the_exporta file changed with no word to the UI, then read again for another reason, shows stale at oncea_name_taken_in_the_batch_does_not_say_a_copy_existsa_name_taken_only_in_this_batch_says_so_and_what_to_do,a_moved_and_changed_source_is_told_true_of_the_copy_in_the_foldersays why the XML left it out, and that its grid or file changed sincecarries the plan's same-name decision...,a row an export in place would refuse says why, once the confirm step is closeda skipped row keeps its reason, never saying how it was exporteda_client_that_says_no_name_is_taken_still_overwrites_nothingsendssameName: falsefor two rows of one name from different sources. One copy is written, the other row is skipped or failed, and the first copy's bytes are unchanged. Three layers each refuse the overwrite: the job's folder check, the transaction, and the no-replace rename. The test fails only once all three are removed.The worst-case
analysedrow still fits its byte budget. The UI was not driven in a browser or the packaged app; it is covered by Vitest withmockIPC.Output change
Docs and dependencies
docs/PRODUCT.md/docs/ARCHITECTURE.mdupdated if behaviour or crate boundaries changed.Output-Change: yes