Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
640867cb
Commit
640867cb
authored
Mar 10, 2016
by
Jason Madden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clean up warnings in subprocess.py. Disable mccabe check for now.
parent
e820c958
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
4 deletions
+20
-4
.landscape.yml
.landscape.yml
+6
-0
gevent/subprocess.py
gevent/subprocess.py
+12
-3
setup.cfg
setup.cfg
+2
-1
No files found.
.landscape.yml
View file @
640867cb
...
@@ -35,6 +35,12 @@ ignore-patterns:
...
@@ -35,6 +35,12 @@ ignore-patterns:
pyroma
:
pyroma
:
run
:
true
run
:
true
mccabe
:
# We have way too many violations of the complexity measure.
# We should enable this and fix them one at a time, but that's
# more refactoring than I want to do initially.
run
:
false
pyflakes
:
pyflakes
:
disable
:
disable
:
# F821: undefined name; caught better by pylint, where it can be
# F821: undefined name; caught better by pylint, where it can be
...
...
gevent/subprocess.py
View file @
640867cb
...
@@ -21,6 +21,15 @@ Cooperative ``subprocess`` module.
...
@@ -21,6 +21,15 @@ Cooperative ``subprocess`` module.
.. _is not defined: http://www.linuxprogrammingblog.com/all-about-linux-signals?page=11
.. _is not defined: http://www.linuxprogrammingblog.com/all-about-linux-signals?page=11
"""
"""
from
__future__
import
absolute_import
,
print_function
from
__future__
import
absolute_import
,
print_function
# Can we split this up to make it cleaner? See https://github.com/gevent/gevent/issues/748
# pylint: disable=too-many-lines
# Import magic
# pylint: disable=undefined-all-variable,undefined-variable
# Most of this we inherit from the standard lib
# pylint: disable=bare-except,too-many-locals,too-many-statements,bad-builtin,attribute-defined-outside-init
# pylint: disable=too-many-branches,too-many-instance-attributes
# Most of this is cross-platform
# pylint: disable=no-member,expression-not-assigned,unused-argument,unused-variable
import
errno
import
errno
import
gc
import
gc
import
io
import
io
...
@@ -155,7 +164,7 @@ __all__ = __implements__ + __imports__
...
@@ -155,7 +164,7 @@ __all__ = __implements__ + __imports__
mswindows
=
sys
.
platform
==
'win32'
mswindows
=
sys
.
platform
==
'win32'
if
mswindows
:
if
mswindows
:
import
msvcrt
import
msvcrt
# pylint: disable=import-error
if
PY3
:
if
PY3
:
class
Handle
(
int
):
class
Handle
(
int
):
closed
=
False
closed
=
False
...
@@ -394,7 +403,7 @@ class Popen(object):
...
@@ -394,7 +403,7 @@ class Popen(object):
# POSIX
# POSIX
if
close_fds
is
_PLATFORM_DEFAULT_CLOSE_FDS
:
if
close_fds
is
_PLATFORM_DEFAULT_CLOSE_FDS
:
# close_fds has different defaults on Py3/Py2
# close_fds has different defaults on Py3/Py2
if
PY3
:
if
PY3
:
# pylint: disable=simplifiable-if-statement
close_fds
=
True
close_fds
=
True
else
:
else
:
close_fds
=
False
close_fds
=
False
...
@@ -669,7 +678,7 @@ class Popen(object):
...
@@ -669,7 +678,7 @@ class Popen(object):
def
__enter__
(
self
):
def
__enter__
(
self
):
return
self
return
self
def
__exit__
(
self
,
t
ype
,
value
,
traceback
):
def
__exit__
(
self
,
t
,
v
,
tb
):
if
self
.
stdout
:
if
self
.
stdout
:
self
.
stdout
.
close
()
self
.
stdout
.
close
()
if
self
.
stderr
:
if
self
.
stderr
:
...
...
setup.cfg
View file @
640867cb
[pep8]
[pep8]
# N801: class names should use CapWords
# N801: class names should use CapWords
ignore=E702,E265,E402,E731,E266,E261,W503,E129,N801
# N802: function names should be lower-case; comes from Windows funcs
ignore=E702,E265,E402,E731,E266,E261,W503,E129,N801,N802
max_line_length=160
max_line_length=160
exclude=.runtimes,.eggs,.tox,.git,build,2.6,2.7,2.7pypy,3.3,3.5,test_support.py,test_queue.py,patched_tests_setup.py,test_threading_2.py,lock_tests.py,_sslgte279.py,3.4
exclude=.runtimes,.eggs,.tox,.git,build,2.6,2.7,2.7pypy,3.3,3.5,test_support.py,test_queue.py,patched_tests_setup.py,test_threading_2.py,lock_tests.py,_sslgte279.py,3.4
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment