fix(storage): 将用户目录移至 data/users - #147
Open
LC044 wants to merge 5 commits into
Open
Conversation
Owner
Author
|
I have read and agree to the CLA |
Deploying trailsnap with
|
| Latest commit: |
8c12657
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://785fb41b.trailsnap-bfa.pages.dev |
| Branch Preview URL: | https://codex-fix-user-storage-root.trailsnap-bfa.pages.dev |
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.
描述
将默认用户存储目录从
data/uploads/users/<user_id>调整为语义更清晰的data/users/<user_id>。直接修改尚未发布的现有一次性数据库迁移:从旧版共享目录
data/uploads/uploads、data/uploads/thumbnails迁移到用户目录,并在迁移完成后安全删除空的旧目录。不会兼容未发布的中间目录data/uploads/users。同时将目录树与批量移动的主存储范围收紧到当前用户的 uploads,并修复导入设置时更新存储缓存缺少 user_id 的问题。
变更类型
相关 Issue
Follow-up to #144 and #145
如何测试
python -m pytest tests/unit/test_user_storage.py tests/unit/test_settings_api.py -q(29 passed)python -m pytest tests/unit/test_user_storage_migration.py tests/unit/test_sqlite_migration_schema.py tests/unit/test_start_database.py -q(6 passed)检查清单