From 1bdbd34e8e258450657a8546063c30937baa52ac Mon Sep 17 00:00:00 2001 From: Jiaming Yuan Date: Thu, 29 Apr 2021 01:01:37 +0800 Subject: [PATCH] Disable pylint error. (#6911) --- python-package/xgboost/core.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-package/xgboost/core.py b/python-package/xgboost/core.py index 4176dcfa9708..ead199e2095a 100644 --- a/python-package/xgboost/core.py +++ b/python-package/xgboost/core.py @@ -2027,7 +2027,7 @@ def dump_model(self, fout, fmap='', with_stats=False, dump_format="text"): """ if isinstance(fout, (STRING_TYPES, os.PathLike)): fout = os.fspath(os.path.expanduser(fout)) - fout = open(fout, 'w') + fout = open(fout, 'w') # pylint: disable=consider-using-with need_close = True else: need_close = False