Skip to content

Commit 1ef8618

Browse files
authored
Merge branch 'master' into channel
Signed-off-by: Lumouille <[email protected]>
2 parents 0035a73 + c0c0b7c commit 1ef8618

File tree

7 files changed

+9
-16
lines changed

7 files changed

+9
-16
lines changed

.github/workflows/docs-localization-download.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
working-directory: ./docs
4141
- name: "Crowdin"
4242
id: crowdin
43-
uses: crowdin/github-action@v2.6.1
43+
uses: crowdin/github-action@v2.7.0
4444
with:
4545
upload_sources: false
4646
upload_translations: false

.github/workflows/docs-localization-upload.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
sphinx-intl update -p ./build/locales ${{ vars.SPHINX_LANGUAGES }}
4545
working-directory: ./docs
4646
- name: "Crowdin"
47-
uses: crowdin/github-action@v2.6.1
47+
uses: crowdin/github-action@v2.7.0
4848
with:
4949
upload_sources: true
5050
upload_translations: false

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ These changes are available on the `master` branch, but have not yet been releas
103103
([#2739](https://github.com/Pycord-Development/pycord/pull/2739))
104104
- Fixed missing `None` type hints in `Select.__init__`.
105105
([#2746])(https://github.com/Pycord-Development/pycord/pull/2746)
106+
- Updated `valid_locales` to support `in` and `es-419`.
107+
([#2767])(https://github.com/Pycord-Development/pycord/pull/2767)
106108
- Fixed parameters for channels And allow creating channels with None as default
107109
reaction ([#2754])(https://github.com/Pycord-Development/pycord/pull/2754)
108110

discord/cog.py

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -151,17 +151,6 @@ def __new__(cls: type[CogMeta], *args: Any, **kwargs: Any) -> CogMeta:
151151

152152
new_cls = super().__new__(cls, name, bases, attrs, **kwargs)
153153

154-
valid_commands = [
155-
(c for i, c in j.__dict__.items() if isinstance(c, _BaseCommand))
156-
for j in reversed(new_cls.__mro__)
157-
]
158-
if any(isinstance(i, ApplicationCommand) for i in valid_commands) and any(
159-
not isinstance(i, _BaseCommand) for i in valid_commands
160-
):
161-
_filter = ApplicationCommand
162-
else:
163-
_filter = _BaseCommand
164-
165154
for base in reversed(new_cls.__mro__):
166155
for elem, value in base.__dict__.items():
167156
if elem in commands:
@@ -178,7 +167,7 @@ def __new__(cls: type[CogMeta], *args: Any, **kwargs: Any) -> CogMeta:
178167
is_static_method = isinstance(value, staticmethod)
179168
if is_static_method:
180169
value = value.__func__
181-
if isinstance(value, _filter):
170+
if isinstance(value, _BaseCommand):
182171
if is_static_method:
183172
raise TypeError(
184173
f"Command in method {base}.{elem!r} must not be"

discord/commands/core.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2042,11 +2042,13 @@ def command(**kwargs):
20422042

20432043
docs = "https://discord.com/developers/docs"
20442044
valid_locales = [
2045+
"id",
20452046
"da",
20462047
"de",
20472048
"en-GB",
20482049
"en-US",
20492050
"es-ES",
2051+
"es-419",
20502052
"fr",
20512053
"hr",
20522054
"it",

requirements/dev.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ pytest~=8.3.5
44
pytest-asyncio~=0.24.0
55
# pytest-order~=1.0.1
66
mypy~=1.15.0
7-
coverage~=7.7
7+
coverage~=7.8
88
pre-commit==4.2.0
99
codespell==2.4.1
1010
bandit==1.8.3

requirements/docs.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ sphinx-copybutton==0.5.2
77
furo==2024.8.6
88
sphinx-autodoc-typehints==2.2.3
99
sphinx-intl==2.3.1
10-
typing_extensions==4.12.2
10+
typing_extensions==4.13.1
1111
levenshtein==0.27.1

0 commit comments

Comments
 (0)