[MacPorts] #44308: py-SRPAstro: switch PIL/Pillow dependency to py-matplotlib and py-scipy.
MacPorts
noreply at macports.org
Fri Jul 18 07:57:13 PDT 2014
#44308: py-SRPAstro: switch PIL/Pillow dependency to py-matplotlib and py-scipy.
-------------------------------------------------+-------------------------
Reporter: ionic@… | Owner: macports-
Type: defect | tickets@…
Priority: Normal | Status: new
Component: ports | Milestone:
Resolution: | Version:
Port: py-SRPAstro py-matplotlib py-scipy | Keywords: haspatch
-------------------------------------------------+-------------------------
Comment (by petr@…):
For `py-matplotlib` there seems to be no strict requirement for PIL
neither. Import are found only in `lib/matplotlib/backend_bases.py`,
`lib/matplotlib/image.py` and `lib/matplotlib/tests/test_image.py`, but
the absence of PIL is handled smoothly. All other occurrences are only in
documentation or examples.
So the missing dependence on PIL seems to be intentional.
From `lib/matplotlib/backend_bases.py`:
{{{
try:
from PIL import Image
_has_pil = True
except ImportError:
_has_pil = False
_backend_d = {}
}}}
From `lib/matplotlib/image.py`
{{{
def pilread(fname):
"""try to load the image with PIL or return None"""
try:
from PIL import Image
except ImportError:
return None
}}}
From `lib/matplotlib/tests/test_image.py`:
{{{
try:
from PIL import Image
HAS_PIL = True
except ImportError:
HAS_PIL = False
}}}
--
Ticket URL: <https://trac.macports.org/ticket/44308#comment:5>
MacPorts <http://www.macports.org/>
Ports system for OS X
More information about the macports-tickets
mailing list