Skip to content

Commit 52e1657

Browse files
committed
Remove unused imports and make exports explicit
This allows Pyright to actually catch these errors, which would be useful for CI purposes in the future.
1 parent f7a79ff commit 52e1657

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

Diff for: discord/__init__.py

+7-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,13 @@
4343
from .widget import *
4444
from .object import *
4545
from .reaction import *
46-
from . import utils, opus, abc, ui, app_commands
46+
from . import (
47+
utils as utils,
48+
opus as opus,
49+
abc as abc,
50+
ui as ui,
51+
app_commands as app_commands,
52+
)
4753
from .enums import *
4854
from .embeds import *
4955
from .mentions import *

Diff for: discord/threads.py

-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@
2626

2727
from typing import Callable, Dict, Iterable, List, Optional, Union, TYPE_CHECKING
2828
from datetime import datetime
29-
import time
30-
import asyncio
3129

3230
from .mixins import Hashable
3331
from .abc import Messageable, _purge_helper

Diff for: pyproject.toml

+1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ exclude = [
4242
"docs",
4343
]
4444
reportUnnecessaryTypeIgnoreComment = "warning"
45+
reportUnusedImport = "error"
4546
pythonVersion = "3.8"
4647
typeCheckingMode = "basic"
4748

0 commit comments

Comments
 (0)