From f023aba0bd9adb733ae8be303a6a807c701e6ff5 Mon Sep 17 00:00:00 2001 From: Hamad alghanim Date: Tue, 17 Oct 2017 01:38:16 -0700 Subject: [PATCH] doc comments for better code --- pipenv/utils.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pipenv/utils.py b/pipenv/utils.py index 95f290d7..69e15319 100644 --- a/pipenv/utils.py +++ b/pipenv/utils.py @@ -916,10 +916,12 @@ def find_requirements(max_depth=3): raise RuntimeError('No requirements.txt found!') def is_valid_url(url): + """Checks if a given string is an url""" pieces = urlparse(url) return all([pieces.scheme, pieces.netloc]) def download_file(url, filename): + """Downloads file from url to a path with filename""" r = requests.get(url, stream=True) if not r.ok: raise IOError('Unable to download file')