8000 Align search filter constants with MyAnimeList's search form by irfan-dahir · Pull Request #653 · jikan-me/jikan · GitHub
[go: up one dir, main page]

Skip to content

Align search filter constants with MyAnimeList's search form - #653

Merged
irfan-dahir merged 2 commits into
masterfrom
v5/search-type-constants
Oct 14, 2026
Merged

irfan-dahir merged 2 commits into
masterfrom
v5/search-type-constants

Conversation

@irfan-dahir
Copy link
Copy Markdown
Collaborator

Part of #636: the concrete defect in that issue. The enum and value-object work it plans is not included.

Search requests send Constants::SEARCH_* values to MyAnimeList unchanged, so a stale constant quietly searches for something else. Checked against the search forms on the recorded search pages, which match the live site (checked today):

Filter MyAnimeList's form Constants before
Anime type 1–9, including 7 CM, 8 PV, 9 TV Special stopped at 6 Music
Manga type 2 Light Novel, 8 Novel SEARCH_MANGA_NOVEL = 2, which was actually Light Novel
Manga status 1–5, including 4 On Hiatus, 5 Discontinued stopped at 3
Anime status, anime rating unchanged already correct

Changes

  • Added:
    • SEARCH_ANIME_CM, SEARCH_ANIME_PV, SEARCH_ANIME_TV_SPECIAL
    • SEARCH_MANGA_LIGHT_NOVEL
    • SEARCH_MANGA_STATUS_ON_HIATUS, SEARCH_MANGA_STATUS_DISCONTINUED
  • Changed: SEARCH_MANGA_NOVEL goes from 2 to 8. Callers using it will now get novels instead of light novels, which is what the name always meant. The changelog tells anyone who wants light novels to switch to SEARCH_MANGA_LIGHT_NOVEL.
  • New test: SearchFormConstantsTest. It compares each group with the <select> on the recorded search pages, by label and by value. When the fixtures are re-recorded, it fails if MyAnimeList adds, removes or renumbers an option.

The full suite and composer quality:static pass.

🤖 Generated with Claude Code

irfan-dahir and others added 2 commits October 14, 2026 16:09
From #636. The search form now offers anime types 7 CM, 8 PV and
9 TV Special, manga type 2 Light Novel / 8 Novel, and manga statuses 4 On Hiatus and
5 Discontinued. SEARCH_MANGA_NOVEL sent 2, which MyAnimeList reads as Light Novel;
it is now 8, with SEARCH_MANGA_LIGHT_NOVEL for 2.

SearchFormConstantsTest compares each constant group (anime/manga type and status,
anime rating) by label and value with the <select> options on the recorded search
pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@irfan-dahir
irfan-dahir merged commit f9ba355 into master Oct 14, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0