mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 22:50:18 +00:00
Merge pull request #4661 from ankitdobhal/refactor
chore : refactor code quality issues
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
version = 1
|
||||
|
||||
test_patterns = ["tests/**"]
|
||||
|
||||
exclude_patterns = [
|
||||
"examples/**",
|
||||
"pipenv/vendor/**",
|
||||
"pipenv/patched/**"
|
||||
]
|
||||
|
||||
[[analyzers]]
|
||||
name = "python"
|
||||
enabled = true
|
||||
|
||||
[analyzers.meta]
|
||||
runtime_version = "3.x.x"
|
||||
+1
-1
@@ -36,7 +36,7 @@ def getpreferredencoding():
|
||||
# Borrowed from Invoke
|
||||
# (see https://github.com/pyinvoke/invoke/blob/93af29d/invoke/runners.py#L881)
|
||||
_encoding = locale.getpreferredencoding(False)
|
||||
if six.PY2 and not sys.platform == "win32":
|
||||
if six.PY2 and sys.platform != "win32":
|
||||
_default_encoding = locale.getdefaultlocale()[1]
|
||||
if _default_encoding is not None:
|
||||
_encoding = _default_encoding
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
import os
|
||||
import sys
|
||||
|
||||
from io import UnsupportedOperation
|
||||
|
||||
from appdirs import user_cache_dir
|
||||
|
||||
from ._compat import fix_utf8
|
||||
|
||||
+1
-1
@@ -726,7 +726,7 @@ class Project(object):
|
||||
if not self.pipfile_exists:
|
||||
return True
|
||||
|
||||
if not len(self.read_pipfile()):
|
||||
if not self.read_pipfile():
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
@@ -47,7 +47,6 @@ PY2_DOWNLOAD = ["enum34"]
|
||||
|
||||
# from time to time, remove the no longer needed ones
|
||||
HARDCODED_LICENSE_URLS = {
|
||||
"pytoml": "https://github.com/avakar/pytoml/raw/master/LICENSE",
|
||||
"cursor": "https://raw.githubusercontent.com/GijsTimmers/cursor/master/LICENSE",
|
||||
"delegator.py": "https://raw.githubusercontent.com/amitt001/delegator.py/master/LICENSE",
|
||||
"click-didyoumean": "https://raw.githubusercontent.com/click-contrib/click-didyoumean/master/LICENSE",
|
||||
|
||||
Reference in New Issue
Block a user