WP-01: Evolution Peewee Models #66
Labels
No Label
ai-changes-requested
ai-failed
ai-merged
ai-pr-opened
ai-reviewed
ai-reviewing
ai-reviewing
ai-working
bug
enhancement
evolution
performance
phase-0
phase-1a
phase-1b
phase-1c
phase-1d
security
tech-debt
todo
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: cal/paper-dynasty-database#66
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
Define Peewee ORM models for the four active evolution tables:
evolution_track,evolution_card_state,evolution_tier_boost,evolution_cosmetic.The old
evolution_milestoneandevolution_progresstables are eliminated — tier thresholds live directly on the track, and card progress is a singlecurrent_valuefloat on the card state.Repo:
databasePhase: 1a (Schema & Data Foundation)
Dependencies: None
Complexity: M
Model Field Summary
EvolutionTrack:id,name,card_type(batter/sp/rp),formula(VARCHAR),t1_threshold(INT),t2_threshold(INT),t3_threshold(INT),t4_threshold(INT)EvolutionCardState:id,player_id(FK),team_id(FK),track_id(FK),current_tier(INT, default 0),current_value(FLOAT, default 0.0),fully_evolved(BOOL, default False),last_evaluated_at(DATETIME, nullable)EvolutionTierBoost/EvolutionCosmetic: Phase 2 stubs, minimal models.Files
database/app/models/evolution.pydatabase/app/db_engine.py— register modelsTests (write first in
database/tests/test_evolution_models.py)Acceptance Criteria
database/app/models/evolution.pymodel_to_dict()works on saved instancesEvolutionTrackincludes formula + threshold columnsEvolutionCardStateincludescurrent_value(FLOAT), noprogress_sincePlan reference:
docs/prd-evolution/PHASE1_PROJECT_PLAN.mdWP-01Implemented and merged as part of the Refractor system rollout. All work packages WP-01 through WP-14 are complete and deployed to dev.