Skip to content

Commit

Permalink
Error message when importing the module readline (for Intel)
Browse files Browse the repository at this point in the history
  • Loading branch information
lecoutre committed Nov 7, 2022
1 parent e9516dc commit a4de2b3
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion tools/inspector.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,14 @@
from pycsp3.tools.utilities import flatten, is_windows

if not is_windows():
import readline
try:
import readline
except ImportError:
if "Intel" in sys.version:
s = 'With Intel compilers, the module readline must be installed by the user.'
else:
s = 'Problem when importing the module readline'
raise ImportError(s)

fileToTrace = [arg for arg in sys.argv if arg.endswith(".py") and "compiler.py" not in arg] + ["<stdin>"]

Expand Down

0 comments on commit a4de2b3

Please sign in to comment.