diff --git a/pipenv/vendor/requirementslib/models/requirements.py b/pipenv/vendor/requirementslib/models/requirements.py index e92fe8ab..28d90799 100644 --- a/pipenv/vendor/requirementslib/models/requirements.py +++ b/pipenv/vendor/requirementslib/models/requirements.py @@ -649,7 +649,8 @@ class VCSRequirement(FileRequirement): # Remove potential ref in the end of uri after ref is parsed if "@" in self.link.show_url and "@" in self.uri: uri, ref = self.uri.rsplit("@", 1) - if self.ref and ref in self.ref: + checkout = self.req.revision + if checkout and ref in checkout: self.uri = uri yield vcsrepo