Repository navigation
Conversation
Runs BattleMenuReader::read_opponent_in_summary() on a 4K summary
screenshot of Persian and expects {"persian"}. The image goes in the
CommandLineTests repo at
PokemonSwSh/MaxLair_SummaryOpponentReader/English_Persian.jpg.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
The summary's type box holds the type badge, e.g. "(O) NORMAL". The letter "O" of the "NORMAL" label is a separate white ring that matches the Normal icon (Persian: 0.368, next to 0.076 for the real icon), and find_type_symbols() drops only overlapping matches. A single-type Normal Pokemon was read as Normal/Normal, matched nothing, and the summary read returned empty. No Pokemon has the same type twice, so treat a repeated type as one type. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AKYzhrMnPK61XHWEch4a6E
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
…e it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AKYzhrMnPK61XHWEch4a6E
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AKYzhrMnPK61XHWEch4a6E
Owner
Author
|
Merged upstream as PokemonAutomation#1882 (in main as 9f19ad7); the diff against main is empty, so closing. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Base
main; no parent PRs; the diff shows only this change. Written upstream-style so it can be handed to PokemonAutomation/Arduino-Source later.Max Lair's summary read returned nothing for single-type Normal opponents (e.g. Persian), because the "O" of the summary's "NORMAL" type label also matches the Normal icon; a repeated type is now read as one type.
Type Read Result: normal : 0.0757804 / normal : 0.367816, then an empty opponent read.find_type_symbols()drops only overlapping matches, so the reader took Normal/Normal, which matches no Max Lair Pokemon.read_opponent_in_summary(), the two-best-types pick moves into a smallsummary_types()helper that sets the second type toNONEwhen it equals the first (no Pokemon has the same type twice). The helper keeps the function under the code-health length limit.PokemonSwSh::MaxLairSummaryOpponentReaderrunsBattleMenuReader::read_opponent_in_summary()(English) on the screenshot and expects{"persian"}.Test image (needs a CommandLineTests PR): the test reads
PokemonSwSh/MaxLair_SummaryOpponentReader/English_Persian.jpgfrom the CommandLineTests repo (3840x2160 JPEG, sha1ce1b524a9fd748afd1c6f01d7f7363ec1c5444e2). The image is the maintainer's screenshot from PokemonAutomation#1851, so we would ask him before adding it to CommandLineTests. Until then the test fails with FileException in CI.Testing
Headless runner (scratch merge of
upstream/headless-tests, not pushed), macOS,SerialProgramsTests --filter MaxLair, image placed locally underbuild/CommandLineTests/:Type Read Result: normal : 0.0777026 / normal : 0.36567, thenFAILED: PokemonSwSh::MaxLairSummaryOpponentReader - ... English_Persian.jpg, Message: Read: (nothing).Disambiguation succeeded: persianandPASSED: PokemonSwSh::MaxLairSummaryOpponentReader - ... English_Persian.jpg.MaxLairBossStatetests pass in both runs.MaxLairBattleMenuDetectorfails in both with FileException only because its CommandLineTests image was not checked out locally.🤖 Generated with Claude Code
https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss