Pillow: Drop support for Python 2 on January 1, 2020

Created on 10 Feb 2019  路  15Comments  路  Source: python-pillow/Pillow

Python 2.7 reaches EOL on 2020-01-01.

This will obviously be a bigger change than dropping other minor versions, so it's a good idea to start thinking about how to proceed and to communicate that sooner rather than later.

Looking at Pillow's PyPI stats, Python 3 accounts for 60% of downloads and is increasing.

image

Here's the pip installs for pillow from PyPI for January 2019:

| category | percent | downloads |
|----------|--------:|----------:|
| 3 | 59.17% | 3,138,659 |
| 2 | 40.03% | 2,123,506 |
| null | 0.79% | 42,021 |
| Total | | 5,304,186 |

Source: pypistats python_major --last-month pillow

| category | percent | downloads |
|----------|--------:|----------:|
| 2.7 | 40.01% | 2,122,431 |
| 3.6 | 34.54% | 1,832,073 |
| 3.5 | 11.78% | 625,070 |
| 3.7 | 10.00% | 530,448 |
| 3.4 | 2.75% | 146,034 |
| null | 0.79% | 42,021 |
| 3.3 | 0.08% | 4,215 |
| 2.6 | 0.02% | 1,075 |
| 3.8 | 0.01% | 753 |
| 3.2 | 0.00% | 66 |
| Total | | 5,304,186 |

Source: pypistats python_minor --last-month pillow

Pip has started warning that Python 2 support will be dropped in a future version and a number of other projects have pledged to drop it no later than 2020. The latest Django 2.x has already dropped it and:

Django 1.11 is the last version to support Python 2.7. Support for Python 2.7 and Django 1.11 ends in 2020.

What should Pillow do?

Ping @python-pillow/pillow-team and anyone else interested!

Deprecation Question

Most helpful comment

I would imagine that dropping Python 2 support is a large enough step to warrant a major version change. So I suggest that Pillow 7.0.0 be the January 1st 2020 release, making Pillow 6 the last series to support Python 2. If so, it would be good to make note of this in the upcoming Pillow 6.0.0 release.

All 15 comments

Why not now? It's not as if py2 users lose access to pillow. they're just stuck with an old version.

I would imagine that dropping Python 2 support is a large enough step to warrant a major version change. So I suggest that Pillow 7.0.0 be the January 1st 2020 release, making Pillow 6 the last series to support Python 2. If so, it would be good to make note of this in the upcoming Pillow 6.0.0 release.

For anyone following this issue, the next release of Pillow, 6.2.0, will be the last release to support Python 2.

Python 2 only issues, to be closed if not fixed before 6.2.0 (2019-10-01):

We can add others here or label with "Python 2-only".

Pillow 6.2.0 has now been released, the last Pillow minor series to support Python 2.7.

Updated stats. Since January, the Python 2 downloads have continued to drop, from 40% to 27%.

image

category | percent | downloads |
|----------|--------:|----------:|
| 3 | 71.50% | 6,877,728 |
| 2 | 27.28% | 2,623,837 |
| null | 1.22% | 117,803 |
| Total | | 9,619,368 |

Date range: 2019-11-01 - 2019-11-30

Source: pypistats python_major --last-month pillow

| category | percent | downloads |
|----------|--------:|----------:|
| 3.6 | 29.97% | 2,882,748 |
| 2.7 | 27.27% | 2,623,376 |
| 3.7 | 24.97% | 2,401,565 |
| 3.5 | 12.36% | 1,188,507 |
| 3.8 | 2.17% | 208,578 |
| 3.4 | 2.03% | 195,703 |
| null | 1.22% | 117,803 |
| 2.6 | 0.00% | 457 |
| 3.9 | 0.00% | 378 |
| 3.3 | 0.00% | 247 |
| 2.4 | 0.00% | 3 |
| 3.2 | 0.00% | 2 |
| 2.8 | 0.00% | 1 |
| Total | | 9,619,368 |

Date range: 2019-11-01 - 2019-11-30

Source: pypistats python_minor --last-month pillow

Wouldn't it be logical to make the last Py2 release after 2.7.18 comes out? a few months later...

CPython 2.7 release schedule:

Support officially stops January 1 2020, but the final release will occur after that date.

https://www.python.org/dev/peps/pep-0373/

All CPython 2.7 core development will stop on 1st January when it enters "code freeze", except for release blockers. Basically, mid-April is the most convenient time for the 2.7 release manager to make the release, who wants it to coincide with PyCon US.

Similarly, we will stop 2.7 development on 1st January. However, we make quarterly releases, so are ready for a 1st January release, and also a 1st April release. The last Pillow 6.2 release will always be available for people using 2.7 after 1st January.

Out of all the downloads...
How many are ...
Unique Downloads
Total Downloads
... and also people who refurbish and clone by #'s also have no representation on the graph. 1 download might equal 1 million installs...

I believe the ship has sailed, and Python 2.7 compatibility has been removed from Master. There is still the option for security updates on the last 6.2.x release branch, but the time for new features working with 2.7 has passed.

FWIW, there is a security release for the 6.2.x series planned for today (#4328) that supports python 2.7.

I anticipate that should there be other similar issues, there will likely be a backport to that branch.

Thanks @radarhere and @python-pillow/pillow-team !!

Pillow 7 has been also been released, without support for Python 2.7.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hxzhao527 picture hxzhao527  路  4Comments

vytisb picture vytisb  路  4Comments

nomarek picture nomarek  路  3Comments

thinrhino picture thinrhino  路  3Comments

indirectlylit picture indirectlylit  路  4Comments