Skip to content

feat: add mono photo schema#52

Merged
trim21 merged 1 commit intobangumi:masterfrom
everpcpc:codex/update-mono-photo-schema
May 3, 2026
Merged

feat: add mono photo schema#52
trim21 merged 1 commit intobangumi:masterfrom
everpcpc:codex/update-mono-photo-schema

Conversation

@everpcpc
Copy link
Copy Markdown
Contributor

@everpcpc everpcpc commented May 3, 2026

Problem

Character and person album APIs in server-private need the dev database to expose the same mono photo schema that exists in the Bangumi database. Without these tables and columns, tests that pull schema/data from dev-env cannot exercise photo lists or photo-related comments.

Approach

Add the shared chii_subject_photos schema used by character/person albums, and update the character/person comment schemas with their related photo columns. The new schema is registered in the SQL load order and expected table checks so rebuilds include it consistently.

Validation

  • Checked that every SQL file under sql/ is listed in sql_script_load_order.txt
  • Checked the new/updated schema files contain the required photo fields
  • Ran git diff --check
  • Did not run full python3 test.py because this local environment is missing pymysql and no MySQL test container was started

Add the shared chii_subject_photos table used by character and person albums, and include it in the SQL load order and expected table checks.

Also update character and person comment schemas with the related photo column required by photo-specific comments.
@everpcpc
Copy link
Copy Markdown
Contributor Author

everpcpc commented May 3, 2026

cc @trim21

@trim21 trim21 merged commit 31572bc into bangumi:master May 3, 2026
1 check passed
@everpcpc everpcpc deleted the codex/update-mono-photo-schema branch May 3, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants