Skip to content
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

the pillow package is broken #1387

Closed
183amir opened this issue Jan 27, 2017 · 11 comments
Closed

the pillow package is broken #1387

183amir opened this issue Jan 27, 2017 · 11 comments
Assignees

Comments

@183amir
Copy link

183amir commented Jan 27, 2017

Similar to #1379 (comment) the pillow package is also broken:

$ conda create -n test python=2 pillow
Fetching package metadata .........
Solving package specifications: ..........

Package plan for installation in environment /home/amir/miniconda/envs/test:

The following NEW packages will be INSTALLED:

    freetype:   2.5.5-2       defaults
    jbig:       2.1-0         defaults
    jpeg:       9b-0          defaults
    libpng:     1.6.27-0      defaults
    libtiff:    4.0.6-3       defaults
    openssl:    1.0.2k-0      defaults
    pillow:     4.0.0-py27_0  defaults
    pip:        9.0.1-py27_1  defaults
    python:     2.7.13-0      defaults
    readline:   6.2-2         defaults
    setuptools: 27.2.0-py27_0 defaults
    sqlite:     3.13.0-0      defaults
    tk:         8.5.18-0      defaults
    wheel:      0.29.0-py27_0 defaults
    xz:         5.2.2-1       defaults
    zlib:       1.2.8-3       defaults

Proceed ([y]/n)? 

Linking packages ...
[      COMPLETE      ]|#################################################################################################################################| 100%
#
# To activate this environment, use:
# > source activate test
#
# To deactivate this environment, use:
# > source deactivate test
#

$ source activate test
$ python -c "import pkg_resources; pkg_resources.require('pillow')"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/amir/miniconda/envs/test/lib/python2.7/site-packages/setuptools-27.2.0-py2.7.egg/pkg_resources/__init__.py", line 968, in require
  File "/home/amir/miniconda/envs/test/lib/python2.7/site-packages/setuptools-27.2.0-py2.7.egg/pkg_resources/__init__.py", line 854, in resolve
pkg_resources.DistributionNotFound: The 'olefile' distribution was not found and is required by pillow

It depends on olefile but it's not a dependency of pillow in the defaults channel.
I suspect this is a new dependency in pillow version 4.

@ilanschnell you might want to consider adding tests like what I proposed here: ContinuumIO/anaconda-recipes#77 to prevent these kind of broken packages early on.

P.S. pillow 4 in conda-forge depends on olefile:

conda-forge.github.io (git) $ python scripts/list_deps.py conda-forge --dependencies olefile
Fetching package metadata .....
msg-extractor 0.2 py27_0 None      : olefile
msg-extractor 0.2 py34_0 None      : olefile
msg-extractor 0.2 py35_0 None      : olefile
pillow 4.0.0 py27_1 None           : olefile
pillow 4.0.0 py35_1 None           : olefile
pillow 4.0.0 py36_1 None           : olefile
@ilanschnell
Copy link
Contributor

Thanks for pointing this out. I will add an olefile package to repository, and as a dependency to pillow. Do you know to which extend Pillow is actually broken by missing olefile?

@183amir
Copy link
Author

183amir commented Jan 28, 2017

The problem is when I try to package another package that depends on pillow, setuptools tries to download olefile. However olefile is not a dependency of that package.

@ilanschnell
Copy link
Contributor

Hmm, but pillow is using setuptools as a build dependency, see: https://github.com/ContinuumIO/anaconda-recipes/blob/master/pillow/meta.yaml#L24 so when you build pillow, it should already try to have downloaded olefile and failed, but it works fine.

Anyway, I'll add olefile as a new dependency of pillow.

@183amir
Copy link
Author

183amir commented Jan 28, 2017 via email

@183amir
Copy link
Author

183amir commented Feb 9, 2017

@ilanschnell looking at conda-forge, the dependency on olefile was not caught in conda-forge too. Rather it was fixed later: conda-forge/pillow-feedstock#25

@anjos
Copy link

anjos commented Feb 13, 2017

@ilanschnell: In Anaconda, you're extensively using --single-version-externally-managed flag for setuptools. I think it implies setuptools defers things such as dependence tracking to the caller - in this case, to conda. Unfortunately, conda is unaware of the dependence to olefile at this point.

@183amir
Copy link
Author

183amir commented Feb 14, 2017

Hi @ilanschnell would it be possible that we see this fixed soon, please? We have a deadline and this is blocking our release. I can make the olefile a dependency of my packages but that is not a very clean solution because they don't depend on it. Thanks.

@ilanschnell
Copy link
Contributor

I was hoping there would be a new pillow release, such that I could combine updating pillow with adding the new olefile dependency. Since that hasn't happened yet, I'm just doing new rebuilding 4.0.0 with the new dependency. Pillow 4.0.0 (build 1) packages should be available shortly.

@183amir
Copy link
Author

183amir commented Feb 14, 2017

Thank you very much @ilanschnell. I think hotfixing the metadata of the build 0 package would have been enough. Is this going to be reflected in anaconda 4.3.0 too? I mean will either pillow 4.0.0-0 be hotfixed or anaconda 4.3.0 depend on pillow 4.0.0-1 or we will have to wait for the next release of anaconda?

Edit: I don't need a fixed anaconda package right away though :) only a fixed pillow package will suffice.

@ilanschnell
Copy link
Contributor

The problem with just hotfixing the metadata would be that then anaconda 4.3.0 would also have to change (and include olefile), so it wouldn't be anaconda 4.3.0 anymore. Anyway the new packages are available now.

@ilanschnell
Copy link
Contributor

Closing issue. Please reopen if there are still issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants