Skip to content

Commit

Permalink
Model updates and fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
gwax committed Feb 21, 2024
1 parent 87e3965 commit 2e55cfc
Show file tree
Hide file tree
Showing 6 changed files with 1,132 additions and 985 deletions.
103 changes: 54 additions & 49 deletions mtg_ssm/scryfall/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,29 +54,30 @@ class ScrySetType(str, Enum):
class ScryCardLayout(str, Enum):
"""Enum for https://scryfall.com/docs/api/layouts#layout."""

NORMAL = "normal"
SPLIT = "split"
FLIP = "flip"
TRANSFORM = "transform"
MODAL_DFC = "modal_dfc"
MELD = "meld"
LEVELER = "leveler"
CLASS = "class"
SAGA = "saga"
ADVENTURE = "adventure"
PLANAR = "planar"
SCHEME = "scheme"
VANGUARD = "vanguard"
TOKEN = "token" # noqa: S105
ART_SERIES = "art_series"
AUGMENT = "augment"
CASE = "case"
CLASS = "class"
DOUBLE_FACED_TOKEN = "double_faced_token" # noqa: S105
DOUBLE_SIDED = "double_sided"
EMBLEM = "emblem"
AUGMENT = "augment"
FLIP = "flip"
HOST = "host"
ART_SERIES = "art_series"
DOUBLE_SIDED = "double_sided"
REVERSIBLE_CARD = "reversible_card"
LEVELER = "leveler"
MELD = "meld"
MODAL_DFC = "modal_dfc"
MUTATE = "mutate"
NORMAL = "normal"
PLANAR = "planar"
PROTOTYPE = "prototype"
REVERSIBLE_CARD = "reversible_card"
SAGA = "saga"
SCHEME = "scheme"
SPLIT = "split"
TOKEN = "token" # noqa: S105
TRANSFORM = "transform"
VANGUARD = "vanguard"


class ScryCardFrame(str, Enum):
Expand All @@ -93,38 +94,40 @@ class ScryFrameEffect(str, Enum):
"""Enum for https://scryfall.com/docs/api/layouts#frame-effects."""

NONE = ""

BORDERLESS = "borderless"
COLORSHIFTED = "colorshifted"
COMPANION = "companion"
COMPASSLANDDFC = "compasslanddfc"
CONVERTDFC = "convertdfc"
DEVOID = "devoid"
DRAFT = "draft"
ETCHED = "etched"
EXTENDEDART = "extendedart"
FANDFC = "fandfc"
FULLART = "fullart"
GILDED = "gilded"
GRAVESTONE = "gravestone"
INVERTED = "inverted"
LEGENDARY = "legendary"
LESSON = "lesson"
MIRACLE = "miracle"
MOONELDRAZIDFC = "mooneldrazidfc"
MOONREVERSEMOONDFC = "moonreversemoondfc"
NYXBORN = "nyxborn"
NYXTOUCHED = "nyxtouched"
DRAFT = "draft"
DEVOID = "devoid"
TOMBSTONE = "tombstone"
COLORSHIFTED = "colorshifted"
INVERTED = "inverted"
SUNMOONDFC = "sunmoondfc"
COMPASSLANDDFC = "compasslanddfc"
ORIGINPWDFC = "originpwdfc"
MOONELDRAZIDFC = "mooneldrazidfc"
MOONREVERSEMOONDFC = "moonreversemoondfc"
WAXINGANDWANINGMOONDFC = "waxingandwaningmoondfc"
SHATTEREDGLASS = "shatteredglass"
SHOWCASE = "showcase"
EXTENDEDART = "extendedart"
COMPANION = "companion"
FULLART = "fullart"
ETCHED = "etched"
SNOW = "snow"
LESSON = "lesson"
STAMPED = "stamped"
SUNMOONDFC = "sunmoondfc"
TEXTLESS = "textless"
SHATTEREDGLASS = "shatteredglass"
CONVERTDFC = "convertdfc"
FANDFC = "fandfc"
UPSIDEDOWNDFC = "upsidedowndfc"
GILDED = "gilded"
BORDERLESS = "borderless"
THICK = "thick"
GRAVESTONE = "gravestone"
TOMBSTONE = "tombstone"
UPSIDEDOWNDFC = "upsidedowndfc"
VEHICLE = "vehicle"
WAXINGANDWANINGMOONDFC = "waxingandwaningmoondfc"


class ScryBorderColor(str, Enum):
Expand Down Expand Up @@ -190,28 +193,30 @@ class ScrySecurityStamp(str, Enum):
class ScryFormat(str, Enum):
"""Enum for card legalities keys."""

ALCHEMY = "alchemy"
BRAWL = "brawl"
COMMANDER = "commander"
DUEL = "duel"
EXPLORER = "explorer"
FRONTIER = "frontier"
FUTURE = "future"
GLADIATOR = "gladiator"
HISTORIC = "historic"
HISTORICBRAWL = "historicbrawl"
LEGACY = "legacy"
MODERN = "modern"
OATHBREAKER = "oathbreaker"
OLDSCHOOL = "oldschool"
PAUPER = "pauper"
PAUPERCOMMANDER = "paupercommander"
PENNY = "penny"
STANDARD = "standard"
VINTAGE = "vintage"
HISTORIC = "historic"
PIONEER = "pioneer"
GLADIATOR = "gladiator"
EXPLORER = "explorer"
HISTORICBRAWL = "historicbrawl"
ALCHEMY = "alchemy"
PAUPERCOMMANDER = "paupercommander"
PREMODERN = "premodern"
PREDH = "predh"
OATHBREAKER = "oathbreaker"
PREMODERN = "premodern"
STANDARD = "standard"
STANDARDBRAWL = "standardbrawl"
TIMELESS = "timeless"
VINTAGE = "vintage"


class ScryLegality(str, Enum):
Expand Down
4 changes: 2 additions & 2 deletions tests/data/bulk_data.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"type": "default_cards",
"name": "Default Cards",
"description": "A JSON file containing every card object on Scryfall in English or the printed language if the card is only available in one language.",
"download_uri": "https://data.scryfall.io/default-cards/default-cards-20230906210610.json",
"updated_at": "2023-09-06T21:06:10.414000Z",
"download_uri": "https://data.scryfall.io/default-cards/default-cards-20240221100428.json",
"updated_at": "2024-02-21T10:04:28.932000Z",
"content_type": "application/json",
"content_encoding": "gzip"
}
Expand Down
Loading

0 comments on commit 2e55cfc

Please sign in to comment.