From 107b433d8587cd18a7c08d20c7a5e08ed13b19a2 Mon Sep 17 00:00:00 2001 From: hided62 Date: Thu, 20 Aug 2026 05:57:06 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20=ED=86=B5=EC=9D=BC=20=EC=99=95=EC=A1=B0?= =?UTF-8?q?=20=EA=B4=80=EC=A7=81=20=EC=82=AC=EC=A7=84=20=EA=B2=BD=EB=A1=9C?= =?UTF-8?q?=20=ED=8F=AD=EC=9D=84=20=EB=B3=B5=EA=B5=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 레거시 emperior 스키마와 동일하게 l12pic부터 l5pic까지 64자를 허용한다. 32자를 넘는 사용자 아이콘 경로를 포함한 통일 원자 트랜잭션 회귀 테스트와 릴리스 마이그레이션 head를 갱신한다. --- .../test/unificationFinalization.integration.test.ts | 8 ++++++-- app/gateway-api/test/releaseManifest.test.ts | 2 +- .../migration.sql | 10 ++++++++++ release-manifest.json | 2 +- 4 files changed, 18 insertions(+), 4 deletions(-) create mode 100644 packages/infra/prisma/migrations/20260820000000_widen_emperor_officer_pictures/migration.sql diff --git a/app/game-engine/test/unificationFinalization.integration.test.ts b/app/game-engine/test/unificationFinalization.integration.test.ts index ac5897c8..d02d1f18 100644 --- a/app/game-engine/test/unificationFinalization.integration.test.ts +++ b/app/game-engine/test/unificationFinalization.integration.test.ts @@ -19,6 +19,7 @@ const fixtureId = 8_901; const serverId = 'che_unification_atomicity_fixture'; const profileName = 'che'; const userId = 'unification-atomicity-user'; +const legacyOfficerPicture = 'users/core/a369f064a434262b025bd2ebc70c60d5.jpg?=20260814'; integration('unification finalization transaction', () => { let db: GamePrismaClient; @@ -118,7 +119,7 @@ integration('unification finalization transaction', () => { dedication: 5, age: 40, crew: 400, - picture: '1.png', + picture: legacyOfficerPicture, turnTime: new Date('0190-07-01T00:00:00.000Z'), meta: { ownerName: '원자 사용자', @@ -354,7 +355,10 @@ integration('unification finalization transaction', () => { aux: { maxPower: 3_500, maxCrew: 400, maxCities: ['원자도시'] }, generals: [fixtureId], }); - expect(await db.emperor.count({ where: { serverId } })).toBe(1); + expect(legacyOfficerPicture.length).toBeGreaterThan(32); + expect(await db.emperor.findFirstOrThrow({ where: { serverId } })).toMatchObject({ + l12pic: legacyOfficerPicture, + }); expect( (await db.inheritancePoint.findUniqueOrThrow({ where: { userId_key: { userId, key: 'previous' } } })) .value diff --git a/app/gateway-api/test/releaseManifest.test.ts b/app/gateway-api/test/releaseManifest.test.ts index d324a5b8..05bd741e 100644 --- a/app/gateway-api/test/releaseManifest.test.ts +++ b/app/gateway-api/test/releaseManifest.test.ts @@ -39,7 +39,7 @@ describe('readReleaseManifest', () => { await expect(readReleaseManifest(workspaceRoot)).resolves.toMatchObject({ controllerProtocol: RELEASE_CONTROLLER_PROTOCOL, gatewaySchemaHead: '20260819000000_backfill_profile_release_source', - gameSchemaHead: '20260819000000_add_general_last_action', + gameSchemaHead: '20260820000000_widen_emperor_officer_pictures', }); }); diff --git a/packages/infra/prisma/migrations/20260820000000_widen_emperor_officer_pictures/migration.sql b/packages/infra/prisma/migrations/20260820000000_widen_emperor_officer_pictures/migration.sql new file mode 100644 index 00000000..c7ada2aa --- /dev/null +++ b/packages/infra/prisma/migrations/20260820000000_widen_emperor_officer_pictures/migration.sql @@ -0,0 +1,10 @@ +-- Ref의 emperior 관직 장수 사진 경로는 VARCHAR(64)다. 사용자 아이콘 URL처럼 +-- 32자를 넘는 정상 경로도 통일 archive에 저장할 수 있도록 원래 폭을 복원한다. +ALTER TABLE "emperior" ALTER COLUMN "l12pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l11pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l10pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l9pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l8pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l7pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l6pic" TYPE VARCHAR(64); +ALTER TABLE "emperior" ALTER COLUMN "l5pic" TYPE VARCHAR(64); diff --git a/release-manifest.json b/release-manifest.json index ed380510..60eadb22 100644 --- a/release-manifest.json +++ b/release-manifest.json @@ -2,6 +2,6 @@ "formatVersion": 1, "controllerProtocol": 2, "gatewaySchemaHead": "20260819000000_backfill_profile_release_source", - "gameSchemaHead": "20260819000000_add_general_last_action", + "gameSchemaHead": "20260820000000_widen_emperor_officer_pictures", "components": ["gateway-api", "gateway-frontend", "release-controller", "game-api", "game-engine", "game-frontend"] }