diff --git a/src/dotenv/main.py b/src/dotenv/main.py index 93d617d6..68ee02a0 100644 --- a/src/dotenv/main.py +++ b/src/dotenv/main.py @@ -275,6 +275,7 @@ def _is_interactive(): current_file = __file__ while frame.f_code.co_filename == current_file: + assert frame.f_back is not None frame = frame.f_back frame_filename = frame.f_code.co_filename path = os.path.dirname(os.path.abspath(frame_filename)) diff --git a/tox.ini b/tox.ini index 0c69795c..a5dc050b 100644 --- a/tox.ini +++ b/tox.ini @@ -22,7 +22,7 @@ commands = skip_install = true deps = flake8 - mypy==0.761 + mypy commands = flake8 src tests mypy --python-version=3.8 src tests