DistributionNotFound running the flake8 on Mac OS X

flake8, pip, python-2.7

Solution

I got the same problem on Linux today. Solved this running:

pip install --upgrade setuptools

Hope to help you too.

Problem

I have trouble running `flake8` after installing it with `pip install flake8`. Reinstalling of `pep8` didn't help. I am running the default python on Mac OS X 10.9.2. My `pep8` version is `1.5.6`. ``` File "/usr/local/bin/flake8", line 5, in <module> from pkg_resources import load_entry_point File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 2603, in <module> working_set.require(__requires__) File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 666, in require needed = self.resolve(parse_requirements(requirements)) File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources.py", line 565, in resolve raise DistributionNotFound(req) # XXX put more info here pkg_resources.DistributionNotFound: pep8>=1.4.6 ```

Original source