Repository navigation
feat(fcd): ship quest goal data over fcd - #2721
Conversation
382 第三十一戦隊 緊急演習, 384 提督との秋祭り演習, 1048/1049 戦略兵站物資. 383 is left out: its period ended at the 2026-09-10 maintenance. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
quest_goal.cson stays bundled as the fallback; fcd/build.js mirrors it into assets/data/fcd/questgoal.json so a new or corrected quest reaches existing installs without a release. Delivered quests are merged over the bundled table per quest id, and existing tracking records keep their progress across the change. Also fixes buildMeta dropping gameselector from meta.json. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
🟡 Changes recommended
One or more issues must be addressed before approval.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Adds FCD delivery for quest-goal definitions while retaining bundled CSON fallback, syncing active quest records, and tracking current limited-time quests.
Changes:
- Adds goal merging and record resynchronization.
- Adds FCD middleware, Redux types/actions, and generated payloads.
- Validates quest data and updates the FCD manifest.
File summaries
| File | Description |
|---|---|
| views/redux/middlewares/quest-goals-fcd.ts | Updated as part of this pull request. |
| views/redux/info/quests/types.ts | Updated as part of this pull request. |
| views/redux/info/quests/index.ts | Updated as part of this pull request. |
| views/redux/info/quests/goals.ts | Updated as part of this pull request. |
| views/redux/info/tests/quest-goals-fcd.spec.ts | Updated as part of this pull request. |
| views/redux/fcd.ts | Updated as part of this pull request. |
| views/redux/create-store.ts | Updated as part of this pull request. |
| views/redux/actions/quest.ts | Updated as part of this pull request. |
| views/redux/actions/index.ts | Updated as part of this pull request. |
| skills/quest-goal-data/SKILL.md | Updated as part of this pull request. |
| fcd/build.js | Updated as part of this pull request. |
| assets/data/quest_goal.cson | Updated as part of this pull request. |
| assets/data/fcd/questgoal.json | Updated as part of this pull request. |
| assets/data/fcd/meta.json | Updated as part of this pull request. |
Review details
Suppressed comments (2)
assets/data/quest_goal.cson:2162
- The new goal lists the bare name
潮, butsatisfyShipmatches each configured name withoptionShipName.includes(goalName), so 満潮・大潮・荒潮 also count toward this eight-ship requirement. That can mark quest 382 progress for fleets containing ships that are not named in the quest; encode an exact-name constraint (or otherwise make this goal use exact matching).
# 花月/桐/榧/杉/樫/竹/潮/響 から5隻以上。'潮' は満潮・大潮・荒潮にも
# substring 一致する(既存の朧・漣・曙・潮の扱いと同じ)
escortship: [
[['花月', '桐', '榧', '杉', '樫', '竹', '潮', '響'], 5]
skills/quest-goal-data/SKILL.md:35
- This command is not valid from either location claimed here:
build.jsreadsmap.json/shiptag.csonand the new../assets/...source relative to the process working directory, sonode fcd/build.jsfrom the repository root looks in the wrong directories, while running it fromfcd/looks forfcd/fcd/build.js. Document the working-directory-safe invocation (or make the script resolve inputs from__dirname).
**After editing the cson, run `node fcd/build.js`** (from the repo root or `fcd/`) and commit
- Files reviewed: 14/14 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| // `src` is read relative to this directory; `outName` is the file written into | ||
| // assets/data/fcd, and defaults to the source's own name with a .json extension. | ||
| async function buildData(src, outName = path.basename(src).replace('.cson', '.json')) { |
| for (const [id, goal] of Object.entries(delivered)) { | ||
| if (goal && typeof goal === 'object') { | ||
| merged[id] = cloneDeep(goal) | ||
| } |
There was a problem hiding this comment.
Review:
Found 1 actionable finding.
A stale cached fcd.questgoal overrides the current bundled quest table
mergeQuestGoals (views/redux/info/quests/goals.ts:68-77) layers the delivered table over the bundled one by replacing a quest definition wholesale (merged[id] = cloneDeep(goal)), and questGoalsFcdMiddleware (views/redux/middlewares/quest-goals-fcd.ts:36-40) re-applies state.fcd.questgoal after every api_get_member/require_info. The fcd slice is restored from localStorage's _storeCache at store creation (views/redux/create-store.ts:31-41, targetPaths includes 'fcd'), and it is refreshed only when the Settings FCD component mounts (views/components/settings/about/update/fcd.tsx:116-119 runs updateData on mount, and :40-59/:61-109 are its only createUpdateFCDAction dispatch sites). Nothing else dispatches createUpdateFCDAction.
Consequence: after an app update, the fcd.questgoal cached by the previous release still contains essentially every quest id. On the next startup, that older payload is layered over the new release's bundled assets/data/quest_goal.cson and replaces the newer bundled definition for every id it contains — not only for the ids it omits. A bundled correction (a fixed required, or an added subgoal) therefore does not take effect until the user opens the update settings page and the local/remote payload happens to refresh. The per-id comment in goals.ts only guards the omitted-id case ("an fcd copy cached before a quest existed must not blank it out"); it does not guard an id that is present in the stale payload but changed in the new bundle, so the stated "bundled cson stays the source/fallback" guarantee is not actually met for that case.
Smallest practical fix: at startup (or in the middleware before dispatching createInfoQuestsGoalsUpdatedAction), compare the cached fcd.questgoal version against the version in the bundled assets/data/fcd/questgoal.json and apply the bundled payload when it is newer, so a stale cache cannot shadow the bundled table. (Merging per subgoal key instead of per quest id would also preserve bundled additions, but at the cost of no longer being able to drop a subgoal.)
「北上改三」、出撃ッ! is 単発 (api_type 4 + api_label_type 1), so it carries no `type`: a reset type would drop the record at the next period boundary and lose progress on a quest that is still open. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Review:
Found 2 actionable findings.
1. A stale cached fcd.questgoal shadows the newer bundled quest table
mergeQuestGoals replaces a bundled quest definition wholesale whenever the delivered payload has that id (views/redux/info/quests/goals.ts:68-76), and questGoalsFcdMiddleware re-applies state.fcd.questgoal after every api_get_member/require_info (views/redux/middlewares/quest-goals-fcd.ts:36-40). The fcd slice is restored from localStorage's _storeCache at store creation (views/redux/create-store.ts:31-41 and :83-97; targetPaths includes 'fcd'), and it is refreshed only by the Settings update component's mount effect (views/components/settings/about/update/fcd.tsx:116-119) — the only site besides the middleware that dispatches createUpdateFCDAction. Because the cached payload was generated from an older quest_goal.cson but still contains essentially every quest id, after an app update it overrides the new release's bundled definitions for every id it has, not only the ids it omits. A bundled correction (a fixed required, an added subgoal, a newly bundled quest) therefore does not take effect until the user opens Settings → About → FCD and the local/remote payload happens to be newer. The comment at goals.ts:62-66 guards only the omitted-id case, so the stated "bundled cson stays the source/fallback" guarantee is not met for ids present in the stale payload.
Smallest fix: before applying the cached payload, compare state.fcd.version.questgoal with the version in the bundled assets/data/fcd/questgoal.json (or seed/refresh the bundled payload at startup) and prefer the bundled table when it is newer, so a stale cache cannot shadow it.
2. The documented fcd/build.js invocation cannot work as written
readCSON reads with fs.readFile(name) and buildData reads JSON with fs.readJSON(src) (fcd/build.js:41-44, :55), both resolved against the process working directory, and the new QUEST_GOAL_SRC = '../assets/data/quest_goal.cson' (:88) assumes the cwd is fcd/. The new instruction in skills/quest-goal-data/SKILL.md:35 says to run node fcd/build.js "from the repo root or fcd/", but from the repository root the script fails immediately: validateShipTag reads 'shiptag.cson' (:73) and validateQuestGoal reads the new source (:90-91) relative to the repo root, where neither exists. The added comment "src is read relative to this directory" (fcd/build.js:46-47) is likewise incorrect. The working invocation remains cd fcd && node build.js, as skills/fcd-assets/SKILL.md:37 already documents.
Fix: resolve all inputs from __dirname (e.g. path.resolve(__dirname, 'shiptag.cson'), path.resolve(__dirname, '../assets/data/quest_goal.cson')) so the documented command works, or correct the doc/comment to the cd fcd form.
Ship names are matched by substring, so 響改二 (Верный) fell out of the 第三十一戦隊 lists in 382 and 1052. Checked every other name list in the file against the remodel chains in api_start2; no other gaps. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Review:
Found 2 actionable findings.
1. A stale cached fcd.questgoal shadows the newer bundled quest table
mergeQuestGoals replaces a bundled quest definition wholesale whenever the delivered payload contains that id (views/redux/info/quests/goals.ts:71-73, merged[id] = cloneDeep(goal)), and questGoalsFcdMiddleware re-applies state.fcd.questgoal after every api_get_member/require_info (views/redux/middlewares/quest-goals-fcd.ts:36-40). The fcd slice is restored at store creation from localStorage's _storeCache (views/redux/create-store.ts:31 lists 'fcd' in targetPaths, and the cache is passed as preloaded state at :83-97), and the only site that dispatches createUpdateFCDAction is the Settings FCD component's mount effect (views/components/settings/about/update/fcd.tsx:116-119, dispatching at :55/:86).
Consequence: after an app update, the payload cached by the previous release still contains essentially every quest id. On the next require_info, that older payload is layered over the new release's bundled assets/data/quest_goal.cson and replaces the newer bundled definition for every id it contains, not only for the ids it omits. A bundled correction (a fixed required, an added/removed subgoal) therefore does not take effect until the user opens Settings → About and the local/remote payload happens to refresh. The goals.ts:62-66 comment only guards the omitted-id case, so the stated "bundled cson stays the source/fallback" guarantee is not met for ids present in the stale payload. Even though the release ships a newer assets/data/fcd/questgoal.json, nothing loads it at startup.
Smallest practical fix: at startup, seed/apply the bundled assets/data/fcd/questgoal.json (or compare state.fcd.version.questgoal against the bundled file's meta.version) and prefer the newer one before the cached payload is merged, so a stale cache cannot shadow the bundled table. Merging per subgoal key instead of per quest id would also preserve bundled additions, but at the cost of no longer being able to drop a subgoal.
2. The documented fcd/build.js invocation fails from the repository root
buildData resolves its src through readCSON/fs.readJSON against the process working directory (fcd/build.js:55), and the new QUEST_GOAL_SRC = '../assets/data/quest_goal.cson' (:88) assumes a cwd of fcd/. The pre-existing validateShipTag reads 'shiptag.cson' (:73) and buildData reads 'map.json' (:113) the same way, while DEST alone is anchored with __dirname (:9). The comment added at :46-47 ("src is read relative to this directory") is incorrect.
The new instruction in skills/quest-goal-data/SKILL.md:35 tells developers to run node fcd/build.js "from the repo root or fcd/". From fcd/ the only working form is node build.js; from the repository root the script fails immediately, because shiptag.cson does not exist there and ../assets/data/quest_goal.cson resolves outside the repository. The correct invocation remains cd fcd && node build.js, as skills/fcd-assets/SKILL.md:37 already documents.
Fix: resolve every input from __dirname (e.g. path.resolve(__dirname, 'shiptag.cson'), path.resolve(__dirname, 'map.json'), path.resolve(__dirname, '../assets/data/quest_goal.cson')) so the documented command works, or correct the doc/comment to the cd fcd form.
|
I've verified both the runtime flow and the build tooling. Here is my review. Findings1. A stale cached
|
…goals fcd state is restored from localStorage, so after an app update the payload cached by the previous release is still present and carries nearly every quest id. Per-id merging alone let it override bundled corrections, so a payload older than this build's own questgoal.json is now discarded. Also resolves fcd/build.js inputs from __dirname, so it runs from either the repo root or fcd/ as documented. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Both review bots raised the same two findings; both are addressed in badc910. 1. Stale cached The claim was that a bundled correction "does not take effect until the user opens Settings → About → FCD". That part is wrong: Blueprint's The underlying concern is still right, and the invariant should not rest on a UI component happening to be mounted: 2. Correct, and it was a pre-existing cwd dependence ( On the suppressed |
There was a problem hiding this comment.
Review:
No actionable findings.
The two defects raised against earlier revisions of this PR are resolved on the head revision. mergeQuestGoals (views/redux/info/quests/goals.ts:107) now compares the delivered meta.version against the version of the bundled assets/data/fcd/questgoal.json and discards a payload older than the build, so a stale fcd.questgoal restored from localStorage can no longer shadow a bundled correction; the middleware supplies that version on both delivery paths (views/redux/middlewares/quest-goals-fcd.ts:42). fcd/build.js resolves all inputs via src() anchored at __dirname (fcd/build.js:43,46,59,77), so the documented node fcd/build.js invocation works from either directory. I re-checked the per-id merge semantics, the resyncQuestRecords progress carry-over, the type-less one-time record handling, and the buildMeta directory enumeration, and did not find a new correctness, security, reliability, or maintainability defect introduced by the diff.
Quest goals name a ship by the master id where it starts counting, and the matcher expands that id through api_aftershipid, so a goal covers every later remodel — renames included — and nothing outside the line. This replaces substring name matching, which over-matched (「潮」 counted 満潮・大潮・荒潮) and missed renamed remodels (響改二 is Верный). It also states 「〜改以降」 exactly, by naming the 改 id instead of the base. All 25 name-based quests are migrated: 68 of 77 ship lists keep an identical match set, and the 9 that change only drop ships that never belonged. The name fields stay for compatibility but are deprecated. escortshipId entries are AND-ed, unlike escortship's OR, so quests 875 and 903 no longer have to encode an AND as a list of OR-ed pairs. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
拡張「六水戦」、最前線へ! asks for 由良改二 or 2 睦月-class ships, which the previous commit flattened into an AND when it moved the quest off the OR-ed escortship field. Adds escortshipIdAny for that case and puts 903 back on OR. Audited the other direction too: of the 94 goal ids that name a remodelled stage, none accepts an unremodelled ship. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Based on my review of the current head (
I found no new correctness, security, or reliability bugs in the merge/resync logic, the record-reset semantics, the One finding: 1. A stale bundled
|
Keeps the id field's semantics identical to the escortship it replaces, so a migrated single-entry list reads the same either way. Only 875 and 1051 need the AND form; 903 goes back to the plain field. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Review:
Found 1 actionable finding.
The bundled payload silently overrides a corrected cson whenever the regeneration step is skipped
mergeQuestGoals (views/redux/info/quests/goals.ts:107-121) layers assets/data/fcd/questgoal.json over the bundled quest_goal.cson per quest id, replacing the bundled definition wholesale, and it does so unless the delivered version is strictly older than the bundled file's version (goals.ts:113-114). The floor is read from that same file (bundledQuestGoalsVersion, goals.ts:65-86). The payload is therefore authoritative at runtime in the ordinary paths:
- on a fresh install the Settings local pass dispatches the bundled file itself (
views/components/settings/about/update/fcd.tsx:45-59), whose version equals the floor, so it is applied; - on an existing install the cached payload's version commonly equals the bundled file's version (same release), so the
<guard does not fire either.
Consequence: if a maintainer edits assets/data/quest_goal.cson (a required fix, a renamed-remodel correction such as the 響/Верный one, an added quest) and does not re-run node fcd/build.js before committing, the committed questgoal.json retains both the old data and the old meta.version. Because the stale payload's version is not less than the (equally stale) bundled version, the version guard does not catch it, and the stale payload replaces the corrected cson for every id it contains — on both fresh and updated installs. The correction silently never ships, defeating the stated "quest_goal.cson stays the single source" invariant. Nothing in package.json (build/test) or CI regenerates or compares the two files; the new validateQuestGoal only validates the cson it is handed (fcd/build.js:94-110), and the documentation relies on the developer remembering the step (skills/quest-goal-data/SKILL.md:35).
Smallest practical fix: add a jest/CI check that derives the data from the cson (reuse the validateQuestGoal + buildData mapping) and asserts it deep-equals the committed assets/data/fcd/questgoal.json's data (ignore meta.version), so a cson edit without regeneration fails the build.
Audited every quest's type against the section it sits under and against the api_type/api_label_type the game reports: - 242 敵東方中枢艦隊を撃破せよ! sat in Weekly with type 3, so its record reset monthly instead of weekly; - 1167 装備の改修集中強化 is weekly with a same-day count, which resetInterval now expresses, so it moves to Weekly instead of posing as a daily; - 313 秋季大演習 is 単発 per the game, so it joins the one-time section and keeps only its daily counter. fcd/build.js now asserts type against the section header, which is what caught the 1167 and 313 placements while fixing them. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
There was a problem hiding this comment.
Review:
Found 1 actionable finding.
A stale bundled questgoal.json silently overrides a corrected quest_goal.cson whenever the regeneration step is skipped
mergeQuestGoals (views/redux/info/quests/goals.ts:107-121) layers the delivered fcd payload over the bundled cson per quest id (merged[id] = cloneDeep(goal), goals.ts:115-119), and it only discards a payload that is strictly older than the floor returned by bundledQuestGoalsVersion() (goals.ts:113-114). That floor is read from assets/data/fcd/questgoal.json (goals.ts:65-86), i.e. from the same generated payload the guard is protecting against. So if a maintainer edits assets/data/quest_goal.cson (a required fix, the renamed-remodel correction such as 響/Верный, or a newly added quest) and does not re-run node fcd/build.js, both the payload's data and its meta.version stay at the old release. The comparison deliveredVersion < bundled is then false (they are equal), so the stale payload replaces the corrected cson for every id it contains.
This is reachable on the ordinary paths, not just a hypothetical: on a fresh install the FCD component's local pass dispatches the shipped questgoal.json unconditionally because '1970/01/01/01' < any real version (views/components/settings/about/update/fcd.tsx:45-57), and on every require_info the new middleware re-applies state.fcd.questgoal (views/redux/middlewares/quest-goals-fcd.ts:36-45, reducer at views/redux/info/quests/index.ts:172-184). Nothing loads the cson after the merge, so the correction is never seen. The result defeats the PR's stated invariant that quest_goal.cson stays the single source, and it is the developer-side mirror of the user-side stale-cache bug the version floor was added to fix. It cannot be caught by the build itself: validateQuestGoal only validates the cson it is handed (fcd/build.js:161-177), nothing in package.json (test is plain jest) or CI regenerates or compares the two files, and the workflow relies on the developer remembering the step (skills/quest-goal-data/SKILL.md).
Smallest practical fix: add a jest/CI check that derives the data from the cson (reuse the validateQuestGoal + buildData mapping, or extract that mapping into a testable module) and asserts it deep-equals the committed assets/data/fcd/questgoal.json's data, ignoring meta.version. That turns "cson is the single source" from a procedural promise into an enforced one, and a cson edit without regeneration fails the build instead of silently shipping stale goals.
The version floor read its bound from the same questgoal.json it was guarding, so a payload at the build's own version still won per quest id. Editing quest_goal.cson without re-running fcd/build.js therefore had no effect at runtime — the developer-side mirror of the stale-cache bug the floor fixed. Equal versions are now treated as carrying nothing new, since the bundled payload is generated from the bundled cson, and a new test compares every committed fcd payload against the source it is built from so the drift fails `npm test` instead of shipping. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Latest review's finding is correct and is fixed in 1f581af. The version floor read its bound from Two changes: Equal versions now count as "nothing new." The bundled payload is generated from the bundled cson, so an equal-version payload either duplicates it (no-op) or is stale (harmful) — there is no case where applying it helps. Only a strictly newer payload, i.e. one that actually came from fcd, is layered on. This makes the "cson is the source" invariant hold regardless of the payload's state. The drift is now a test failure, not a procedure. Worth flagging that the review's suggestion to "reuse the |
There was a problem hiding this comment.
Review:
No actionable findings.
The id-based ship matching (shipRemodelSources plus the flagshipId/secondshipId/escortshipId/escortshipIdAll checks), the per-quest-id fcd merge with its strictly-newer version floor, resyncQuestRecords, the type-less one-time handling, and the fcd/build.js __dirname/manifest changes are internally consistent and covered by the added tests (renamed remodels, remodel cycles, OR vs AND escorts, equal/older payload versions, and payload/source drift). I found no concrete correctness, security, reliability, or maintainability defect introduced by this diff.
|
I've completed an adversarial review of the current head ( I traced the full data flow (merge, version floor, middleware ordering, plugin-window The three previously-raised findings are genuinely fixed:
No new high-confidence findings. Things I checked that came close but do not clear the bar:
I verified the migrated ship ids (響=35/響改=235/Верный=147, 潮=16/潮改=233/潮改二=407, 朧=93/漣=94/曙=15, 夕張改二=622→改二特=623→改二丁=624 cycle, etc.) against the |
A goal with no type must never lose progress to a period rollover. Covers the record side (day/week/month/quarter and all 12 yearly resets, plus 400 day steps), the active-quest side (expiry keys off the game's api_type, and 4 matches no branch), and the require_info path that re-reads quest_tracking with the file's own timestamp. setup-tests.ts now defines APPDATA_PATH, without which questTrackingPath throws and the tracking load silently falls back to an empty table. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
I reviewed the full diff against the base ( FindingsNo high-confidence findings on the current head. I verified that the three issues raised in earlier review rounds are genuinely fixed and independently confirmed the fixes are complete:
Things I checked that came close but do not clear the bar:
|
There was a problem hiding this comment.
Review:
No actionable findings.
The head revision holds up under independent inspection: the per-quest-id fcd merge with its strictly-newer version floor, the resyncQuestRecords carry-over, the type-less one-time reset convention, the master-id/remodel-line ship matching (including renamed remodels and switchable cycles), and the fcd/build.js __dirname plus manifest/drift-test changes are internally consistent and covered by the added tests. I could not construct a concrete correctness, security, reliability, or maintainability defect introduced by this diff.
What
Quest goal definitions now ship over fcd as well, with the bundled cson kept as the fallback, plus tracking for the limited-time quests that are still in period.
Quest data
Adds the limited-time (期間限定) quests to a new section at the end of
quest_goal.cson:practice_win_a, 5+ of 花月/桐/榧/杉/樫/竹/潮/響, daily resetpractice_win(B+ counts), 4+ of the 17 named ships, daily resetLeft out on purpose, with the reasons recorded in the file: 383 フランス艦隊、特別演習 (period ended at the 2026-09-10 maintenance — an expired id must not be tracked, since the game reuses limited-time ids), 199 第三十一戦隊 特務編成 (composition-only; the engine matches events and there is no fleet-organisation event), and 秋祭り拡張演習 (id not yet observed).
Capture presence after the last maintenance is the reliable signal that a quest is live; absence proves nothing, because a quest also disappears from
questlistonce cleared. Periods were confirmed against the maintenance notes.One-time quests
Adds 1052 改装多目的搭載母艦「北上改三」、出撃ッ! — S victory ×2 at 1-3, 2-4 and 4-5, flagship 北上改三 plus 2+ of 花月/潮/響/竹/桐/榧/杉/樫 — in a new
One-time (単発)section, and establishes the encoding for that class of quest.typeexists only to drive record resets, and the game marks one-time questsapi_type 4+api_label_type 1. Such an entry deliberately carries notype: any reset type would delete the record at the next period boundary and throw away progress on a quest that is still open. NewoutdateRecordstests cover this, and pin down a related detail — a resettypewins overresetInterval, so atype: 4record is deleted outright at a quarter boundary and re-created from the goals on the nextquestlistresponse.Ships are matched by master id, not by name
Ship constraints now name a master ship id — the id where a ship starts counting — and the matcher expands it through
api_aftershipid, so a goal covers that ship and every later remodel and nothing outside the line. NewflagshipId/secondshipId/escortshipIdalongside the old name fields, which are deprecated.This fixes both directions of the substring matching it replaces:
'潮'also counted 満潮・大潮・荒潮・黒潮・朝潮・親潮・早潮 — quests 350 and 1005 (「第七駆逐隊」) have been mis-counting for as long as they have been tracked;escortshipIdkeepsescortship's OR semantics — one entry is enough — so a migrated list reads the same either way.escortshipIdAllis the AND form for the two quests that want two escort groups together (875, 1051); everything else is either a single entry (45 subgoals) or an OR (903).All 25 name-based quests are migrated (97 distinct names, each resolving to exactly one master ship by exact name). To check the rewrite was faithful I diffed the old substring match set against the new id match set, ship by ship: 68 of 77 lists are identical, and all 9 that differ only drop ships that never belonged — no list gained anything unintended. The five multi-entry
escortshipblocks were converted by hand, becauseescortshipIdentries are AND-ed whereescortship's were OR-ed:escortshipIdand matches the game again;escortshipIdAllentries;The remodel graph is not a chain: switchable variants (最上改二 ⇄ 最上改二特) form cycles and 24 ships are reachable from more than one remodel, so the expansion is a reachability walk with a seen set, memoised per
$shipsidentity.On 改/改二 quests specifically, since naming a stage is the whole point: of the 94 migrated goal ids that name a remodelled stage, none accepts an unremodelled ship — a 改-or-later quest can no longer pass a base ship, which is not something the substring form could guarantee. The one nuance is switchable variants:
[622](夕張改二) also accepts 改二特 and 改二丁, which is exactly what quest 903 asks for. Eleven new tests cover the expansion, the id matching,escortshipIdOR vsescortshipIdAllAND, and the base-ship exclusion on a real cycle line (夕張).Renamed remodels
satisfyShipmatches ship names by substring, so a remodel that is renamed silently stops matching: 響改二 is 「Верный」, which'響'does not match. Both new 第三十一戦隊 lists (382, 1052) now carry'響', 'Верный'. Every other name list in the file was checked against the remodel chains inapi_start2master data — no other gaps — and the skill now records all 13 renamed remodels in the roster (雪風→丹陽, 大鯨→龍鳳, U-511→呂500, Littorio→Italia, …) so the next edit does not repeat this.1170 既存装備活用による対空兵装の開発 stays untracked with the rest of the 工廠 family: its scrap counters would be trackable, but only if
destory_itemdispatches carried the first fleet's flagship, which the quest requires and the event does not pass.fcd delivery
assets/data/quest_goal.csonstays the single source and the bundled fallback;fcd/build.jsmirrors it intoassets/data/fcd/questgoal.json, so a new or corrected quest can reach existing installs without a release.views/redux/info/quests/goals.ts— parses the bundled table once, merges the delivered one over it per quest id (a delivered quest replaces the bundled one wholesale, so fcd can fix arequiredor drop a subgoal; ids the payload omits keep their bundled definition, because a cached payload can predate the build). Same reasoning asgameselector. Consequence: fcd can correct a quest but never delete one.resyncQuestRecordscarries progress across a goal change — a count survives arequiredcorrection (clamped), a dropped subgoal's record goes away, a new one starts atinit.views/redux/middlewares/quest-goals-fcd.tsre-applies the merge on@@updateFCD/@@replaceFCDand after everyrequire_info, since either can come first andrequire_inforeloads the bundled table. It acts on post-action state, unlikequestsCrossSliceMiddleware.fcd/build.jsvalidates the cson before building (numeric ids, at least one subgoal, positiverequired), andbuildMetanow enumeratesassets/data/fcd/instead of a hardcoded list — which also fixes a latent bug where any build run droppedgameselectorfrommeta.jsonand silently stopped its delivery.Delivering a new filter field still needs a release: the payload carries data only, and an older build ignores a field its matcher does not know.
Reset-period audit
Checked every quest's
type— the field that drives record resets — against both the section it sits under and theapi_type/api_label_typethe game reports. Three were wrong:type: 3, so poi held its record for a month while the game reset it weekly. A long-standing bug, not something this PR introduced.resetInterval: 1expresses it properly now, so it becomestype: 2in the Weekly section.api_type 4/label 1), so it joins the one-time section and keeps only its daily counter.fcd/build.jsnow assertstypeagainst the section header, which is what caught the 1167 and 313 placements as I moved them. 138 quests, 0 mismatches after the fix.Everything else in the audit came back clean: no unknown events or fields, no invalid
required/init, everymapareain master data, everymapcella real edge of its map, everymissionname andslotitemIdin master data, every ship id a player ship, and no goal wanting S where the quest text says A (or vice versa).Two discrepancies I deliberately left alone: 211/212 are
api_type 5/label 7(quarterly) in the API but poi treats them as special dailies (type: 8/9, plus theapi_no === 211 || api_no === 212case infilterActiveQuestFactory). The captures back poi up — both cycle through clear-and-reappear within days (211 cleared 08-10, active again 08-13, cleared 08-18, …) — so the existing special case stays.Test
views/redux/info/__tests__/quest-goals-fcd.spec.ts— 15 new cases: merge fallback / override / addition, the record re-sync behaviours, and both delivery orders including the plugin-window@@replaceFCDpath.outdateRecordstests inquests.spec.tsfor the one-time (notype) convention.satisfyShip/shipRemodelSourcestests for id matching: renames, 改-and-later, no over-match, AND-ed entries, flagship position.npx jest→ 477 passed, 42 suites.npx jest --runTestsByPath views/redux/info/__tests__/quests.spec.ts views/redux/info/__tests__/quest-goals-fcd.spec.ts→ 32 passed.npm run typecheckand eslint clean;node fcd/build.jsis idempotent and bumps the version when the data changes.🤖 Generated with Claude Code