We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent afe4117 commit 3fbc2efCopy full SHA for 3fbc2ef
tools/update_requirements.py
@@ -2,7 +2,10 @@
2
import sys
3
from pathlib import Path
4
5
-import tomli
+try:
6
+ import tomllib
7
+except ImportError:
8
+ import tomli as tomllib
9
10
if sys.version_info < (3, 6):
11
print('This script requires Python 3.6 to work correctly')
@@ -15,7 +18,7 @@
15
18
doc_reqs = repo_root / 'doc-requirements.txt'
16
19
17
20
with open(pyproject_toml, 'rb') as fobj:
- config = tomli.load(fobj)
21
+ config = tomllib.load(fobj)
22
requirements = config['project']['dependencies']
23
doc_requirements = config['project']['optional-dependencies']['doc']
24
0 commit comments