Rebuild tag-based subdecks when dissolving block exam subdecks#1210
Draft
RisingOrange wants to merge 6 commits intoNRT-432from
Draft
Rebuild tag-based subdecks when dissolving block exam subdecks#1210RisingOrange wants to merge 6 commits intoNRT-432from
RisingOrange wants to merge 6 commits intoNRT-432from
Conversation
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.
This PR improves compatibility between block exam subdecks and subdeck tag features by ensuring notes return to their proper tag-based subdecks when a block exam subdeck is dissolved.
Related issues
Proposed changes
1. Refresh tag-based subdecks on subdeck dissolution
2. Rename function for clarity
move_subdeck_to_main_deck()→dissolve_block_exam_subdeck()3. Update tests and documentation
test_dissolve_subdeck_with_subdecks_enabledHow to reproduce
Testing subdeck tag compatibility (main feature):
AnkiHub_Subdeck::AnKing_Overhaul_for_Step_1_&_2::footo a noteTesting the unit tests:
All three test cases should pass:
test_dissolve_block_exam_subdeck_success- Basic dissolution without subdeck rebuildingtest_dissolve_subdeck_with_subdecks_enabled- Dissolution with subdeck rebuilding for AnkiHub decks (key test)test_dissolve_subdeck_not_found- Error handling when subdeck doesn't existScreenshots and videos
N/A - The feature works behind the scenes to maintain subdeck tag organization.
Further comments
Why this matters:
Block exam subdecks and subdeck tags serve different purposes:
Without this change, dissolving a block exam subdeck would leave notes orphaned in the main deck, breaking the tag-based subdeck organization. This PR ensures the two features work together properly - block exam subdecks can be created and dissolved without disrupting the underlying tag-based subdeck structure.