chore: refresh metagame feeds - #6954
Conversation
📝 WalkthroughWalkthroughThe PR refreshes four MTGGoldfish feed snapshots to August 3, 2026. It updates Commander deck data, reorders and replaces Modern decks, refreshes Pioneer lists and sideboards, and replaces the Standard Mardu Discard entry with Izzet Self-Bounce. ChangesMTGGoldfish feed refresh
Estimated code review effort: 3 (Moderate) | ~30 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@client/public/feeds/mtggoldfish-commander.json`:
- Line 14: Update the Doctor Doom deck’s colors entry from an empty array to
["U", "B", "R"], preserving the feed’s existing color-code format and JSON
validity.
- Around line 18-377: Update the Doctor Doom deck entries in the main list to
use bare card names without printing decorations, set identifiers, foil markers,
or variant tags. Preserve each card’s count and ensure names such as “Doctor
Doom, King of Latveria” resolve through resolve_deck_list like the commander.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: a40f5c61-964b-4d0e-8963-d2bf9dea15d2
📒 Files selected for processing (4)
client/public/feeds/mtggoldfish-commander.jsonclient/public/feeds/mtggoldfish-modern.jsonclient/public/feeds/mtggoldfish-pioneer.jsonclient/public/feeds/mtggoldfish-standard.json
| "U", | ||
| "R" | ||
| ], | ||
| "colors": [], |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
colors is empty for a three-color deck.
The Doctor Doom deck runs Island, Swamp, and Mountain (lines 271-282) plus blue, black, and red spells. Every other deck in this feed declares its colors. An empty array marks this deck as colorless for any consumer that filters or renders by color. Set ["U", "B", "R"].
🔧 Proposed fix
- "colors": [],
+ "colors": [
+ "U",
+ "B",
+ "R"
+ ],As per path instructions: "Verify JSON validity and consistency after updating timestamps, deck ordering, card quantities, sideboards, and deck entries".
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "colors": [], | |
| "colors": [ | |
| "U", | |
| "B", | |
| "R" | |
| ], |
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@client/public/feeds/mtggoldfish-commander.json` at line 14, Update the Doctor
Doom deck’s colors entry from an empty array to ["U", "B", "R"], preserving the
feed’s existing color-code format and JSON validity.
Source: Path instructions
| "name": "Scavenger Grounds" | ||
| "name": "Drowned Catacomb [LTC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Barren Moor" | ||
| "name": "Smoldering Marsh <019eb2ae-3d0a-7b98-95e0-615b2140b6c3> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Forgotten Cave" | ||
| "name": "Rogue's Passage [LCC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Lonely Sandbar" | ||
| "name": "Secluded Courtyard <019edcec-b41b-79c0-9c38-a74cc3b191a5> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Geier Reach Sanitarium" | ||
| "name": "Shipwreck Marsh [MID]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Spymaster's Vault" | ||
| "name": "Stormcarved Coast <borderless> [VOW] (F)" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Sulfur Falls" | ||
| "name": "Terramorphic Expanse <019edced-1f35-70a8-ade2-bad31e5a7009> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Path of Ancestry" | ||
| "name": "Sunken Hollow <019edced-01a6-7455-b838-7633f1e08183> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Crumbling Necropolis" | ||
| "name": "Scorched Geyser <019edcec-af89-7a8d-a263-f0b0501e2751> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Drowned Catacomb" | ||
| "name": "Haunted Ridge [MID]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Dragonskull Summit" | ||
| "name": "Plaza of Heroes [DMU]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Scorched Geyser" | ||
| "name": "Villainous Hideout <019edce9-9436-7560-9f32-4059f8803ac8> [MSH]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Smoldering Marsh" | ||
| "name": "Luxury Suite <019edceb-f388-74e7-87c3-2ed4e2713ac7> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Foreboding Ruins" | ||
| "name": "Fabled Passage <019d4a1a-a82d-71f3-a23b-c05440b9bd9c> [SOC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Ash Barrens" | ||
| "name": "Choked Estuary <019edce9-f343-78da-82ad-354a51ae5c83> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Sulfurous Springs" | ||
| "name": "Unclaimed Territory <019edced-6f11-789b-9aad-fef6215e415b> [MSC]" | ||
| }, | ||
| { | ||
| "count": 5, | ||
| "name": "Swamp" | ||
| "count": 1, | ||
| "name": "Blood Crypt [ECL]" | ||
| }, | ||
| { | ||
| "count": 5, | ||
| "name": "Island" | ||
| "count": 1, | ||
| "name": "Shizo, Death's Storehouse [DMC]" | ||
| }, | ||
| { | ||
| "count": 5, | ||
| "name": "Mountain" | ||
| "count": 1, | ||
| "name": "Path of Ancestry <019edcec-549b-71b3-93a1-701f1bf568f7> [MSC]" | ||
| }, | ||
| { | ||
| "count": 1, | ||
| "name": "Doctor Doom, King of Latveria" | ||
| "name": "Doctor Doom, King of Latveria <019e89cd-782a-7403-97b4-32f281557cee> [MSC] (F)" |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# Description: Confirm decorated card names are unique to this deck and check JSON validity across all feeds.
set -euo pipefail
fd -e json . client/public/feeds --exec sh -c 'python3 -c "import json,sys; json.load(open(sys.argv[1]))" "$1" && echo "valid: $1"' _ {}
echo "--- entries with printing decorations, per feed ---"
fd -e json . client/public/feeds --exec sh -c '
echo "== $1"
python3 - "$1" <<PY
import json,sys,re
d=json.load(open(sys.argv[1]))
pat=re.compile(r"\[[A-Z0-9]{3,4}\]|<[^>]+>|\(F\)$")
for deck in d.get("decks",[]):
hits=[c["name"] for c in deck.get("main",[]) if pat.search(c.get("name",""))]
print(deck.get("name"), "decorated:", len(hits), "of", len(deck.get("main",[])))
PY' _ {}Repository: phase-rs/phase
Length of output: 3529
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== feed schema and Doctor Doom metadata =="
python3 - <<'PY'
import json
p="client/public/feeds/mtggoldfish-commander.json"
d=json.load(open(p))
deck=d["decks"][0]
print("deck keys:", sorted(deck))
print("name:", deck.get("name"))
print("colors:", deck.get("colors"))
print("main entries:", len(deck.get("main", [])))
print("main total:", sum(x["count"] for x in deck.get("main", [])))
print("commander field:", deck.get("commander"))
for x in deck["main"]:
if "Doctor Doom" in x["name"]:
print("commander-like entries:", x)
PY
echo "== relevant loader source =="
sed -n '530,640p' crates/phase-ai/src/bin/ai_duel.rs
echo "== feed consumers and name normalization =="
rg -n -C 3 'mtggoldfish-commander|deck\\[\"main\"\\]|get_face_by_name|commander|colors' crates client --glob '*.rs' --glob '*.ts' --glob '*.tsx' --glob '*.js' --glob '*.jsx' | head -300Repository: phase-rs/phase
Length of output: 27590
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== PlayerDeckList consumers in ai_duel.rs =="
rg -n -C 8 'main_deck|commander|PlayerDeckList|load_commander_decks' crates/phase-ai/src/bin/ai_duel.rs
echo "== card-name resolution for loaded deck lists =="
rg -n -C 5 'get_face_by_name|main_deck.*name|deck.*main_deck|commander.*get_face|PlayerDeckList' crates --glob '*.rs' | head -500Repository: phase-rs/phase
Length of output: 50370
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "== server-side deck resolution =="
sed -n '1,110p' crates/server-core/src/deck_resolve.rs
echo "== engine deck-list resolution =="
rg -n -C 10 'fn resolve_deck_list|pub fn resolve_deck_list|resolve_player_deck_list' crates/engine crates/engine-wasm --glob '*.rs'
echo "== exact decorated-name impact =="
python3 - <<'PY'
import json, re
p="client/public/feeds/mtggoldfish-commander.json"
deck=json.load(open(p))["decks"][0]
strip=lambda s: re.sub(r"\s*(?:<[^>]*>|\[[^]]*\]|\(F\))", "", s).strip()
names=[x["name"] for x in deck["main"]]
print("decorated entries:", sum(strip(n) != n for n in names))
print("exact bare-name matches:", sum(n == deck["name"] for n in names))
print("normalized commander matches:", sum(strip(n) == deck["name"] for n in names))
print("normalized total:", sum(x["count"] for x in deck["main"] if strip(x["name"]) != deck["name"]))
PYRepository: phase-rs/phase
Length of output: 15429
Strip printing decorations from the Doctor Doom deck card names.
load_commander_decks passes these names unchanged to resolve_deck_list, which silently drops every unresolvable decorated name. The deck therefore loads with an empty main deck, while the bare deck name still resolves as its commander. Use bare card names, as in the other feed decks.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@client/public/feeds/mtggoldfish-commander.json` around lines 18 - 377, Update
the Doctor Doom deck entries in the main list to use bare card names without
printing decorations, set identifiers, foil markers, or variant tags. Preserve
each card’s count and ensure names such as “Doctor Doom, King of Latveria”
resolve through resolve_deck_list like the commander.
Source: Path instructions
Automated daily metagame feed refresh from MTGGoldfish.
Summary by CodeRabbit