Update Pyright to v1.1.394

This commit is contained in:
Rapptz
2025-02-18 03:16:51 -05:00
parent 1cdf710908
commit 8953938a53
30 changed files with 94 additions and 81 deletions

View File

@ -219,14 +219,15 @@ class Interaction(Generic[ClientT]):
int(k): int(v) for k, v in data.get('authorizing_integration_owners', {}).items()
}
try:
self.context = AppCommandContext._from_value([data['context']])
value = data['context'] # pyright: ignore[reportTypedDictNotRequiredAccess]
self.context = AppCommandContext._from_value([value])
except KeyError:
self.context = AppCommandContext()
self.locale: Locale = try_enum(Locale, data.get('locale', 'en-US'))
self.guild_locale: Optional[Locale]
try:
self.guild_locale = try_enum(Locale, data['guild_locale'])
self.guild_locale = try_enum(Locale, data['guild_locale']) # pyright: ignore[reportTypedDictNotRequiredAccess]
except KeyError:
self.guild_locale = None