[CI] Update lint configuration to support latest pylint convention (#4971)

* Update lint configuration

* Use gcc 8 consistently in build instruction
This commit is contained in:
Philip Hyunsu Cho 2019-10-21 16:40:57 -07:00 committed by GitHub
parent 4771bb0d41
commit 741fbf47c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 6 deletions

View File

@ -375,7 +375,7 @@ Create the ``build/`` directory and invoke CMake with option ``R_LIB=ON``. Make
mkdir build mkdir build
cd build cd build
CC=gcc-7 CXX=g++-7 cmake .. -DR_LIB=ON CC=gcc-8 CXX=g++-8 cmake .. -DR_LIB=ON
make -j4 make -j4
make install make install

View File

@ -4,7 +4,7 @@ ignore=tests
extension-pkg-whitelist=numpy extension-pkg-whitelist=numpy
disable=unexpected-special-method-signature,too-many-nested-blocks,useless-object-inheritance disable=unexpected-special-method-signature,too-many-nested-blocks,useless-object-inheritance,import-outside-toplevel,unsubscriptable-object
dummy-variables-rgx=(unused|)_.* dummy-variables-rgx=(unused|)_.*

View File

@ -984,7 +984,7 @@ class DMatrix(object):
# validate feature name # validate feature name
try: try:
if not isinstance(feature_names, str): if not isinstance(feature_names, str):
feature_names = [n for n in iter(feature_names)] feature_names = list(feature_names)
else: else:
feature_names = [feature_names] feature_names = [feature_names]
except TypeError: except TypeError:
@ -1028,7 +1028,7 @@ class DMatrix(object):
try: try:
if not isinstance(feature_types, str): if not isinstance(feature_types, str):
feature_types = [n for n in iter(feature_types)] feature_types = list(feature_types)
else: else:
feature_types = [feature_types] feature_types = [feature_types]
except TypeError: except TypeError:

View File

@ -153,8 +153,7 @@ class RabitTracker(object):
except socket.error as e: except socket.error as e:
if e.errno in [98, 48]: if e.errno in [98, 48]:
continue continue
else: raise
raise
sock.listen(256) sock.listen(256)
self.sock = sock self.sock = sock
self.hostIP = hostIP self.hostIP = hostIP