PHP-Color icon indicating copy to clipboard operation
PHP-Color copied to clipboard

Library/Test is Broken

Open ireksawicki opened this issue 8 years ago • 2 comments

Hi,

After recent commit the library running on PHP 7 is failing.

Class 'projectcleverweb\color\data\validate' not found

Here's the printscreen with the full trace: http://prntscr.com/gkjjli

best, I.

ireksawicki avatar Sep 13 '17 07:09 ireksawicki

The library is being refactored so it can support more complex operations. These new operations will allow you to edit colors based on how humans actually observe color. This will allow features such as emulating color blindness, more fluid gradients, better schemes, etc.

At the moment, half the unit tests are now broken or depreciated, and until the refactoring is done more and more tests will break. Unit testing fixes will come a few commits down the road after the refactor is complete. Until then please use the following code to revert to a more stable commit:

git reset --hard dfd287476deee32bc5200ab06988dc9db84ed4ed

That commit should be pretty stable. However, please keep in mind that this library is in its developmental phase. Despite how simple it appears, the mathematics and operations needed to manipulate colors in programming can be very complex, and there are often several official ways to do what is supposed to be the same thing.

I will update and close this issue and when the refactor is complete, so you can start using the latest development again.

Sorry for any convenience this has caused. I will fix it as soon as I am able to.

ProjectCleverWeb avatar Sep 13 '17 16:09 ProjectCleverWeb

Hi ProjectCleverWeb,

Thanks for the reply. I just wanted to report broken PHP 7 version - and it's not only about the tests, but the normal runtime too. :) All you have to do to reproduce it is just simple new projectcleverweb\color\main('#ffffff') on PHP7.

I've already forked this lib with reverted last commit yesterday but thanks for the advice.

I'm sure it was not easy to handle all the equations. Overall this library does a great job if it comes to color manipulations in the PHP - thank you for developing and sharing it!

Best, I.

ireksawicki avatar Sep 13 '17 16:09 ireksawicki