refactor: move CollectionHelper to :anki-common#21349
Draft
david-allison wants to merge 6 commits into
Draft
Conversation
Prep for moving CollectionHelper to :anki-common. Collection creation will become a startup concern, but collection access will move to :anki-common. * Part of 19552 * Part of 13574 * Part of 20737 Assisted-by: Claude Fable 5
Breaking change, this was previously done on first collection access. Now this is set in AnkiDroidApp, and reading throws StorageNotConfiguredException beforehand. This contains a workaround for the OS-level bug: `SystemStorageException` if the exception is caught, it is explicitly rethrown. This is preparation for a full 'storage decision' screen during onboarding * Part of 19552 * Part of 13574 * Part of 20737 Assisted-by: Claude Fable 5
The decision now mirrors whether `getCurrentAnkiDroidDirectory` is usable or throws. The path is set during startup (`ensureCollectionPathSet`), so `Undecided` is only observable if startup storage initialization failed. This is now classified as an `InitializationError` and displayed in the app startup flow (with a TODO for 19552 to improve this). * Part of 19552 * Part of 13574 Assisted-by: Claude Fable 5
* Part of 20737 Assisted-by: Claude Opus 4.8
Assisted-by: Claude (Opus 4.8 & Fable 5)
Assisted-by: Claude Fable 5
5 tasks
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.
Purpose / Description
Should be a simple migration commit once the dependency is in
Fixes
How Has This Been Tested?
Trusting lint & unit tests
Checklist