Port patches from 1.0.0 branch (#5336)
* Remove f-string, since it's not supported by Python 3.5 (#5330) * Remove f-string, since it's not supported by Python 3.5 * Add Python 3.5 to CI, to ensure compatibility * Remove duplicated matplotlib * Show deprecation notice for Python 3.5 * Fix lint * Fix lint * Fix a unit test that mistook MINOR ver for PATCH ver * Enforce only major version in JSON model schema * Bump version to 1.1.0-SNAPSHOT
This commit is contained in:
committed by
GitHub
parent
8aa8ef1031
commit
7ac7e8778f
@@ -5,6 +5,8 @@ Contributors: https://github.com/dmlc/xgboost/blob/master/CONTRIBUTORS.md
|
||||
"""
|
||||
|
||||
import os
|
||||
import sys
|
||||
import warnings
|
||||
|
||||
from .core import DMatrix, Booster
|
||||
from .training import train, cv
|
||||
@@ -19,6 +21,12 @@ try:
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
if sys.version_info[:2] == (3, 5):
|
||||
warnings.warn(
|
||||
'Python 3.5 support is deprecated; XGBoost will require Python 3.6+ in the near future. ' +
|
||||
'Consider upgrading to Python 3.6+.',
|
||||
FutureWarning)
|
||||
|
||||
VERSION_FILE = os.path.join(os.path.dirname(__file__), 'VERSION')
|
||||
with open(VERSION_FILE) as f:
|
||||
__version__ = f.read().strip()
|
||||
|
||||
Reference in New Issue
Block a user