update: storage path

This commit is contained in:
tao.chen
2026-08-13 09:35:27 +08:00
parent 302bda2ee9
commit da9a1ec472
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -251,7 +251,7 @@ multipart/binary 形式上传大文件(走 server-proxied PUT,详见 §九)。
| `visibility` | enum | |
| `status` | `active` \| `deleted` | |
| `is_locked` | boolean | 是否锁定。`PUT /scripts/{id}`(§3.8) 受此字段门禁;可通过 §3.16 切换 |
| `relative_path` | string \| null | 例如 `users/alice/scripts/etl/train.py` |
| `relative_path` | string \| null | 例如 `workspace/01HXX.../scripts/etl/train.py`(以 `user_id` 为作用域) |
| `content_hash` | string \| null | SHA-256 十六进制 |
| `size_bytes` | int | |
| `created_at` / `updated_at` | ISO-8601 | |
+1 -1
View File
@@ -100,7 +100,7 @@ TREE_EXCLUDED_USAGE_TYPES = (
def user_relative_path(context: RequestContext, child_path: str = "") -> str:
base = f"users/{context.user.username}"
base = f"workspace/{context.user.user_id}"
normalized = normalize_user_path(child_path)
return f"{base}/{normalized}" if normalized else base