Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ci] [python-package] Add CI job testing compatibility with oldest possible versions #5936
[ci] [python-package] Add CI job testing compatibility with oldest possible versions #5936
Changes from all commits
3fd1abc
92e239b
7427793
413d959
af94ad9
9df09cd
f417967
3dd2c89
be64783
634d337
c2d1602
16d67a2
381b047
e56b022
f79f17a
483fe83
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why only these examples? Why not any
dask
ones or the plotting one?numpy
,scikit-learn
,pandas
, andscipy
introduce very few additional dependencies. For example, from the CI logs:(build link)
dask
, on the other hands, introduces many more. Withdask[array,dataframe,distributed]==2.0.0
installed in that same environment, here's whatpip freeze
shows:I don't want to take on the maintenance burden of making all of those things continue working on Python 3.6.
And as for the plotting examples... similar concern. They rely on some sometimes-hard-to-build graphics libraries like
graphviz
andtkinter
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not running the whole test suite? We would need a couple more dependencies like cloudpickle and psutil and some minor changes to some tests but it'd work. That'd allow us to prevent introducing a breaking change for py36.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is exactly what I meant when I said in #5759 (comment) that "I don't want to take on any more support than [a minimal CI job] for Python 3.6". In this project that's already struggling from a severe lack of maintainer attention and availability, I don't think we should be taking on the maintenance burden of trying to keep all the tests working with Python 3.6, which also implies keeping them working with:
pytest
lightgbm
+ in its testsIn this PR's current state, we get a new CI job that'll confirm that on every commit, the Python package...
I think that's an incremental improvement over the current state, and honestly good enough. I don't support reverting #4891 and trying to say this project fully and completely supports Python 3.6.
If you feel really strongly that we should go farther than this PR does, how about this... could we merge this as-is, and then you could put up a follow-up PR that adds running the unit tests?
According to https://pypistats.org/packages/lightgbm, only around 3-6% of
lightgbm
installations from PyPI are for Python 3.6 these days.I don't know the equivalent number for conda, but it must be lower, given that both Anaconda and conda-forge have stopped supporting Python 3.6 (and even Python 3.7 already!).
Per https://conda.io/projects/conda/en/latest/user-guide/tasks/manage-python.html
And per https://conda-forge.org/docs/user/announcements.html#dropping-python-3-7 and conda-forge/conda-forge-pinning-feedstock#2623
conda-forge
dropped support for Python 3.7 in August 2022 (10 months ago).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Totally agree.
This is for publishing new versions of packages, right? You can still create an env with python 3.6 from conda-forge.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah I think you're right. I just tried that on my Mac with
mambaforge
:And it worked, albeit with some fairly old versions:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the same image we use for building the wheels published to PyPI.
LightGBM/.vsts-ci.yml
Lines 21 to 22 in ac57d5a
LightGBM/.vsts-ci.yml
Lines 36 to 38 in ac57d5a
It's also not possible, as of #5759, to run
sh build-python.sh
inPython < 3.7
, since:scikit-build-core
has a floor ofPython >= 3.7
setuptools
for Python 3.6,v59.6.0
(December 2021), doesn't supportpyproject.toml
So as of #5759, Python 3.6 users will have to use the published wheels. Customizations like
--cuda
will require building the wheel in a Python 3.7+ environment and then distributing it into wherever that Python 3.6 code is running.I think Python 3.6 users should be expect to face issues for many packages (not just LightGBM) as a result of the changes in the Python packaging ecosystem described in #5061.