-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Do not install unsupported Pillow for Python 3.8+ #9118
Comments
Thanks for reporting this. We are working on the "Future builders" ( |
I did a quick query to our database and I found 1.5k projects in this situation (
It may be worth prioritizing a potential solution here to avoid re-compile Pillow over and over for these projects. |
This should now be deployed, if you could confirm it's working 👍 |
Yes, this is working insofar as it's installing a Pillow wheel suitable for the Python version, and not slowly building an old version from source. Thank you! Before deploy:
After deploy:
I would prefer not having to install unused dependencies: they may install quickly, but we're still unnecessarily downloading from PyPI, multiplied by every build, which has a huge (although 100% discounted) $1.8m/month bill. We touched on it here python/devguide#933 (comment) and python/devguide#933 (comment). Quick investigation: Here's the same docs built using
And adding in the extra dependencies:
So not too much slower: about 4s, but about 8.5 MB (+44 %) more download. But my fork project is new; older projects also download/install sphinx<2 (3.1 MB)/sphinx-rtd-theme<0.5 (6.4 MB)/etc, before possibly re-downloading/installing modern versions/themes. This is an extra ~10 MB and +~100%. Anyway, I'm happy this is a good improvement, that we can override the build process if needed, and you have a long term plan too. Thank you very much! |
@hugovk thanks for opening this issue and for your quick investigation.
Yeap. New projects do not pin I could enable the feature flag I opened an internal discussion to find out a clean way to avoid installing Read the Docs' core dependencies under some circumstances without involving |
Details
Expected Result
Unnecessary dependencies are not installed (related #8208), and do not slow down the build.
Actual Result
https://docs.readthedocs.io/en/stable/build-default-versions.html#external-dependencies says that Pillow 5.4.1 is an external dependency and that it "could be removed in the future".
We require Python 3.9 to build the PEPs docs and do not need Pillow.
Pillow 5.4.1 (released Jan 2019) supported Python 2.7 and 3.4-3.7, which means binary wheels are only available for those versions. Pillow 8.0 is the first version support to Python 3.9 with binary wheels:
This means Python 3.9 downloads the big sdist and builds from source, which is much slower than installing from wheel:
Some suggestions, in my order of preference:
I'm focusing on Pillow here as the main bottleneck, but we probably don't need most of the other external dependencies, and would prefer to only install things we've explicitly specified.
But if we can begin by addressing Pillow, that would be a good first step. Thank you!
The text was updated successfully, but these errors were encountered: