From 6ed7ad64f3a7d97a9c1c3a355ed736ce2bd8729f Mon Sep 17 00:00:00 2001 From: xjw0914 Date: Fri, 15 Sep 2017 11:06:20 +0800 Subject: [PATCH] Fix NoneType. --- pipenv/project.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pipenv/project.py b/pipenv/project.py index 59837db4..85ee9e99 100644 --- a/pipenv/project.py +++ b/pipenv/project.py @@ -42,6 +42,8 @@ class Project(object): @property def name(self): if self._name is None: + if not self.pipfile_exists: + exit(1) self._name = self.pipfile_location.split(os.sep)[-2] return self._name