Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ACCOUNT-V1 seems to be using the wrong region for PH. #451

Closed
CarlVictorV opened this issue May 10, 2024 · 1 comment
Closed

ACCOUNT-V1 seems to be using the wrong region for PH. #451

CarlVictorV opened this issue May 10, 2024 · 1 comment

Comments

@CarlVictorV
Copy link
Contributor

import cassiopeia as cass
from cassiopeia import Account

def print_summoner(name: str, tagline: str, region: str):
    account = Account(
        name=name,
        tagline=tagline,
        region=region,
    )
    summoner = account.summoner
    print(summoner)


if __name__ == "__main__":
    print_summoner("Pobelter", "NA1", "NA") #Americas
    print_summoner("Kalturi", "NA1", "NA") #Americas
    print_summoner("Kaiser10", "JP1", "JP") #Asia
    print_summoner("KaiserV", "GOW", "PH") #SEA
    print_summoner("Omega", "SG2", "SG") #SEA
    #SEA is not a correct region for accounts-v1

After testing out Cassiopeia, I realized that it does not work for the Philippines or Southeast Asia regions.

Making call: https://asia.api.riotgames.com/riot/account/v1/accounts/by-riot-id/Kaiser10/JP1
Summoner(id=?, account_id=?, puuid='T62kOSc4Gj4mUSty2hNLTkXzU0GTOJC6hAX1FrMkElhNJW_STobine2AQ8lLusIHFyPv5ywnKTeULA')
Making call: https://sea.api.riotgames.com/riot/account/v1/accounts/by-riot-id/KaiserV/GOW
Traceback (most recent call last):
.... errors

It uses 'sea' even though it's not a valid choice for account/v1.

@jjmaldonis
Copy link
Member

Thanks for the report and the code to reproduce. This is now fixed in version 5.1.2

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

No branches or pull requests

2 participants