Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion data/v2/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@
"front_default": ("pokemon/versions/generation-vi/icons/", "png"),
"front_female": ("pokemon/versions/generation-vi/icons/female/", "png"),
},
"omegaruby-alphasapphire": {
"omega-ruby-alpha-sapphire": {
"front_default": (
"pokemon/versions/generation-vi/omegaruby-alphasapphire/",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @FallenDeity what do you think about changing the naming also on the sprites repo? I know we would break some applications but for the sake of consistency maybe it's a good move?

@FallenDeity FallenDeity Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah having it consistent would be nice I can make a separate change for this later this weekend I'll need to expose the new sprites I added as well will do it in one go then

I need to make a few folder changes/additions for gen 8 as well so it would fit in nicely with that

@Naramsim Naramsim Sep 30, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, I set a banner on the homepage. I set a go-live date to next week the 7th. If you don't have time we can postpone with no issues.

@santichausis can you modify this PR to take into account this change? Either now or after @FallenDeity will update the sprites repo.

On the 7th then we can merge the sprites PR and then this PR.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure. I'll wait for the sprites repo PR so I can check the new paths against it, then update the gen-vi entries in POKEMON_SPRITE_CONFIG and the test that pins the folder name, well before the 7th. @FallenDeity since you'll also be exposing new sprites and changing gen 8 folders, let me know if you'd rather handle the config side yourself in one go, to avoid conflicting edits in build.py.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I switched the gen-vi ORAS paths to pokemon/versions/generation-vi/omega-ruby-alpha-sapphire/ and updated the test, so it now requires every gen-vi group's key and sprites folder to match. Heads-up: the sprites repo still has the old omegaruby-alphasapphire folder, so this needs to land after the sprites rename. If merged before it, all ORAS sprites would resolve to null.

"png",
Expand Down
18 changes: 18 additions & 0 deletions pokemon_v2/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from django.test import TestCase
from typing_extensions import override

from data.v2.build import POKEMON_SPRITE_CONFIG, _resolve_sprite_config
from pokemon_v2.models import *


Expand Down Expand Up @@ -228,3 +229,20 @@ def test_identifier_pattern_examples(self):
self.VALID_IDENTIFIER_PATTERN.match(identifier),
f"{identifier} should be invalid but was accepted",
)


class PokemonSpriteConfigTestCase(TestCase):
Comment thread
FallenDeity marked this conversation as resolved.
# regression test for https://github.com/PokeAPI/pokeapi/issues/1684:
# the generation-vi Omega Ruby/Alpha Sapphire sprite dict key must match
# the real version-group name ("omega-ruby-alpha-sapphire"), not the
# sprites repo's folder name ("omegaruby-alphasapphire") used in the paths.
def test_generation_vi_oras_sprite_key_matches_version_group_name(self):
gen_vi = POKEMON_SPRITE_CONFIG["versions"]["generation-vi"]
self.assertIn("omega-ruby-alpha-sapphire", gen_vi)
self.assertNotIn("omegaruby-alphasapphire", gen_vi)

def test_resolved_sprite_config_uses_version_group_name_as_key(self):
resolved = _resolve_sprite_config(POKEMON_SPRITE_CONFIG, lambda path, extension: f"{path}.{extension}")
gen_vi = resolved["versions"]["generation-vi"]
self.assertIn("omega-ruby-alpha-sapphire", gen_vi)
self.assertNotIn("omegaruby-alphasapphire", gen_vi)
Loading