Skip to content

Commit 121d59a

Browse files
authored
[MO] move importlib-metadata into setup.py (#10319)
* handle 'and' marker in requirements * Revert "handle 'and' marker in requirements" This reverts commit 952bb94. * moved importlib-metadata from requirements.txt into setup.py
1 parent f1557c0 commit 121d59a

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

tools/mo/requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,3 @@ urllib3>=1.26.4
1111
requests>=2.25.1
1212
fastjsonschema~=2.15.1
1313
openvino-telemetry>=2022.1.0
14-
importlib-metadata; python_version < "3.8" and sys_platform == "win32"

tools/mo/setup.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,16 @@ def read_text(path):
4242
# Minimal set of dependencies
4343
deps_whitelist = ['networkx', 'defusedxml', 'numpy', 'openvino-telemetry']
4444

45-
# for py37 and less on Windows need importlib-metadata in order to use entry_point *.exe files
46-
if sys.platform == 'win32' and sys.version_info[1] < 8:
47-
deps_whitelist.append('importlib-metadata')
48-
4945
deps = []
5046
with open('requirements.txt', 'rt') as req_file:
5147
for line in req_file.read().split('\n'):
5248
if line.startswith(tuple(deps_whitelist)):
5349
deps.append(line)
5450

51+
# for py37 and less on Windows need importlib-metadata in order to use entry_point *.exe files
52+
if sys.platform == 'win32' and sys.version_info[1] < 8:
53+
deps.append('importlib-metadata')
54+
5555

5656
class InstallCmd(install):
5757
def run(self):

0 commit comments

Comments
 (0)