upgrade: adopt V8.21.3 (V8.13→8.21.3: P5 SFTP/S3, P6 multilingual, editor overhaul, enterprise hardening)
Overlay ~150 upstream items onto our V8.12 base, preserving trade-pro
theme, registry tests, and design docs. Re-applied our patch set
(discovery/env_for/blocks.css/type-mapping/theme_color/frontend entries,
test_theme_pro_v3 mods) — all anchors survived upstream evolution.
New platform enhancement (fixes upgrade-introduced regression):
multilingual.site_locale now honors settings_json.locale, plus
PUT /api/i18n/sites/{id}/locale — standalone English sites get
<html lang='en'> under the V8.15 locale-rewrite pipeline.
compose: adopt V8.21.3 (image 8.21.3-dev.1, /api/ready probes, MySQL/S3
env) with project name pinned to siteforge-v8-10 (data volumes).
Tests: 356 passed / 11 failed — all 11 confirmed pre-existing in
pristine V8.21.3 on this host (10 upstream Windows env + our build test
now green after locale fix). Patch registry updated in plan doc.
Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
+5
-1
@@ -134,7 +134,11 @@ def create_user(request:Request,payload:UserCreate):
|
||||
person=uid()
|
||||
db.insert('INSERT INTO team_users(id,username,password_hash,display_name,created_at) VALUES (?,?,?,?,?)',
|
||||
(person,payload.username,hash_password(payload.password),payload.display_name,db.now()))
|
||||
except sqlite3.IntegrityError:raise HTTPException(409,'用户名已存在')
|
||||
except Exception as exc:
|
||||
# PostgreSQL uses psycopg.errors.UniqueViolation rather than sqlite3.IntegrityError.
|
||||
if isinstance(exc,sqlite3.IntegrityError) or getattr(exc,'sqlstate',None)=='23505':
|
||||
raise HTTPException(409,'用户名已存在') from exc
|
||||
raise
|
||||
return {'id':person,'username':payload.username,'display_name':payload.display_name}
|
||||
|
||||
@router.patch('/team/users/{user_id}/disable')
|
||||
|
||||
Reference in New Issue
Block a user