I'm actually trying to import sacrebleu, but sacrebleu uses portalocker, and I get the following error (after it tries to import portalocker):
File “run.py”, line 52, in <module>
import sacrebleu
File “/Users/username/miniconda3/envs/local_nmt/lib/python3.5/site-packages/sacrebleu/__init__.py”, line 21, in <module>
from .utils import smart_open, SACREBLEU_DIR, download_test_set
File “/Users/username/miniconda3/envs/local_nmt/lib/python3.5/site-packages/sacrebleu/utils.py”, line 8, in <module>
import portalocker
File “/Users/username/miniconda3/envs/local_nmt/lib/python3.5/site-packages/portalocker/__init__.py”, line 41
LOCK_EX: constants.LockFlags = constants.LockFlags.EXCLUSIVE
^
SyntaxError: invalid syntax
Not sure what's going on here — does anyone have any insight? Let me know if there's any additional context that might be helpful!
Edit: Python version is 3.7.9!