Make pypi in nbdev results in "ModuleNotFoundError: No module named 'pkg_resources"


I am trying to push one nbdev package to PyPi. I’ve just followed the tutorial of the nbdev documentation, and when I execute make pipy, I get the following:

make pypi
rm -rf dist
python sdist bdist_wheel
Traceback (most recent call last):
  File "", line 1, in <module>
    from pkg_resources import parse_version
ImportError: No module named pkg_resources
Makefile:26: recipe for target 'dist' failed
make: *** [dist] Error 1

Any ideas? I am pretty sure it must e something basic I am missing.