tybug / ossapi

The definitive python wrapper for the osu! api.
https://tybug.github.io/ossapi/
GNU Affero General Public License v3.0
80 stars 17 forks source link

`beatmap_user_scores` returns generic list of `Score` instead of `BeatmapUserScore` #73

Closed ItsMestro closed 1 year ago

ItsMestro commented 1 year ago

Idk whether the type hint is just wrong or if the return type is meant to be different but using beatmap_user_scores() returns a List[Score] instead of the stated List[BeatmapUserScore] and breaking type hints.

tybug commented 1 year ago

Thanks for the report! The type hint is wrong here; it should be List[Score].

That said, I'm not sure why the osu api returns a Score for that endpoint instead of a BeatmapUserScore. The latter makes more sense to me. Regardless, I've fixed the type hint for the next release.