vaab / colour

Python color representations manipulation library (RGB, HSL, web, ...)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

IOError: [Errno 2] No such file or directory: '/Library/Python/2.7/site-packages/rgb.txt'

priestc opened this issue · comments

Right after doing a pip install colour I get this error when I try to call the Color constructor. I think you may have a bug in your setup.py file.

Here is a solution, I can't figure out how to do a pull request across forked repos:

priestc@afb7e96

Hi, thank you for your report.

It's quite strange this doesn't work. I've tested it extensively under Linux and I know several users of this library that didn't have any issue (and they would have complained since not finding this file will cast exception at import time).

I guess that I didn't test on Mac OSX. And I should have.

Anyway, at first I wanted to keep this file out because it's a file that exists in any X installation in this precise form (and with the same name). But as time passes, I see that keeping this file along the package have been really tedious, and that its not completely supported on all plateforms (this is a nasty flaw of python packaging system I guess). Apart of being tedious to keep, it wasn't so usefull to have this in a separate file.

So I'm willing to integrate your proposition, this would greatly simplify all these. But I have a small request:

The original matching between colornames and their actual hex representation in rgb.txt is very close to W3C color naming recommandation but it doe not follow it exactly on some subtle points. I would rather see "colour" python module stick to the W3C color naming recommandation in case of divergence. So could you check and replace the divergent values by the W3C one ? It seems a relatively small job if you use the 'color name chart' in http://en.wikipedia.org/wiki/X11_color_names, which would help sport these divergence quite conveniently.

Thank you again for the improvement you suggest.