Conversation
* Support project type in apis & models * Refine project type compatibility boundaries * Tighten project type API contract * Add type validation in local helpers
Document the route canonicalization contract in `docs/openapi.yaml`, including moved-route responses and query normalization. Signed-off-by: Aofei Sheng <aofei@aofeisheng.com>
Handle moved-resource responses from the backend without generic write retries, and retry updateProject once with the canonical route so saving existing projects still works after a project rename. Replace unresolved user, project, and editor routes with canonical backend values after loading so subsequent UI behavior uses canonical identifiers consistently. Updates #2993 Signed-off-by: Aofei Sheng <aofei@aofeisheng.com>
There was a problem hiding this comment.
Code Review
This pull request introduces a robust mechanism for handling resource renames and route normalization for users and projects. Key changes include updating the OpenAPI specification to support 301 and 409 responses with canonical metadata, enhancing the API client to parse this metadata, and implementing automatic route redirection in the frontend when a historical username or project name is accessed. Additionally, a type field (defaulting to game) has been added to projects across the API and UI. Review feedback identifies a high-severity issue where route normalization watchers on the project, user, and editor pages may trigger incorrectly due to stale data during navigation; it is recommended to gate these redirects with a loading state check. A potential regression in the asset library search behavior was also noted.
[skip review]