File tree Expand file tree Collapse file tree 3 files changed +16
-9
lines changed Expand file tree Collapse file tree 3 files changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -108,6 +108,9 @@ repos:
108
108
rev : v0.931
109
109
hooks :
110
110
- id : mypy
111
+ additional_dependencies :
112
+ - types-pyOpenSSL
113
+ - types-requests
111
114
- repo : https://github.com/asottile/pyupgrade
112
115
rev : v2.31.0
113
116
hooks :
Original file line number Diff line number Diff line change 1
1
"""The pshtt library."""
2
+ # Standard Python Libraries
3
+ from typing import List
4
+
2
5
# We disable a Flake8 check for "Module imported but unused (F401)" here because
3
6
# although this import is not directly used, it populates the value
4
7
# package_name.__version__, which is used to get version information about this
5
8
# Python package.
6
9
from ._version import __version__ # noqa: F401
7
10
8
- __all__ = []
11
+ __all__ : List [ str ] = []
Original file line number Diff line number Diff line change 17
17
from . import utils
18
18
from .models import Domain , Endpoint
19
19
20
- try :
21
- # Standard Python Libraries
22
- from urllib import parse as urlparse # Python 3
23
- except ImportError :
20
+ if sys .version_info .major == 2 :
24
21
# Third-Party Libraries
25
- import urlparse # Python 2
22
+ import urlparse
23
+ elif sys .version_info .major == 3 :
24
+ # Standard Python Libraries
25
+ from urllib import parse as urlparse
26
26
27
- try :
27
+ if sys .version_info .major == 2 :
28
+ # Third-Party Libraries
29
+ from urllib2 import URLError
30
+ elif sys .version_info .major == 3 :
28
31
# Standard Python Libraries
29
32
from urllib .error import URLError
30
- except ImportError :
31
- from urllib2 import URLError
32
33
33
34
# Third-Party Libraries
34
35
import sslyze
You can’t perform that action at this time.
0 commit comments