Skip to content

Commit f987d8b

Browse files
removed robotframework from requirements.txt and added additional dependency checks to robottools/__init__.py instead
--HG-- branch : dev
1 parent c17aa64 commit f987d8b

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

requirements.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,3 @@ six >= 1.10
33
path.py >= 8.0 #import path
44
moretools >= 0.1.8
55
modeled >= 0.1.8
6-
#py2 robotframework >= 2.8.7 #import robot
7-
#py3 robotframework-python3 >= 2.8.7 #import robot

robottools/__init__.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
"""
2626

2727
from zetup import find_zetup_config
28+
from zetup.version import Version
2829

2930
zfg = find_zetup_config(__name__)
3031

@@ -38,6 +39,17 @@
3839

3940
## __notebook__ = zfg.NOTEBOOKS['README']
4041

42+
try:
43+
import robot
44+
except ImportError as exc:
45+
raise ImportError(
46+
"%s depends on robotframework but import failed with: %s"
47+
% (repr(__distribution__), exc))
48+
if Version(robot.__version__) < '2.8.7':
49+
raise __import__('pkg_resources').VersionConflict(
50+
"%s needs robotframework>=2.8.7 but found %s in %s"
51+
% (repr(__distribution__), robot.__version__, repr(robot)))
52+
4153
from robottools.library import *
4254
from robottools.library.keywords import *
4355
from robottools.library.session import SessionHandler

0 commit comments

Comments
 (0)