We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ba8c549 commit 31d8c9cCopy full SHA for 31d8c9c
checkdmarc/bimi.py
@@ -14,10 +14,11 @@
14
import hashlib
15
16
try:
17
- import importlib.resources as pkg_resources
+ from importlib.resources import files
18
except ImportError:
19
- # Try backported to PY<37 `importlib_resources`
20
- import importlib_resources as pkg_resources
+ # Try backported to PY<3 `importlib_resources`
21
+
22
23
import dns
24
import requests
@@ -60,7 +61,7 @@
60
61
62
# Load the certificates included in MVACAs.pem into a certificate store
63
X509STORE = X509Store()
-with pkg_resources.path(checkdmarc.resources, "MVACAs.pem") as path:
64
+with str(files(checkdmarc.resources).joinpath("MVACAs.pem")) as path:
65
66
CA_PEMS = pem.parse_file(path)
67
for CA_PEM in CA_PEMS:
0 commit comments