diff --git a/measurements/word_length/word_length.py b/measurements/word_length/word_length.py index 5b31cd2d..873fa3c9 100644 --- a/measurements/word_length/word_length.py +++ b/measurements/word_length/word_length.py @@ -20,6 +20,12 @@ import evaluate +if evaluate.config.PY_VERSION < version.parse("3.8"): + import importlib_metadata +else: + import importlib.metadata as importlib_metadata + + NLTK_VERSION = version.parse(importlib_metadata.version("nltk")) _DESCRIPTION = """