Closed rabbiveesh closed 5 years ago
It isn't a missing dependency, but it is a difference between how Mojo::JSON works and Cpanel::JSON::XS. Mojolicious tries to use Cpanel::JSON::XS if it can (and on my laptop and on Travis, the module is available). If it's not available, Mojolicious uses Mojo::JSON. Both of these have boolean implementations so we can use true
or false
in code.
Unfortunately, Cpanel::JSON::XS says it uses JSON::PP::Boolean, but it instead re-implements it with additional overloads. These additional overloads makes the tests work correctly for me, but makes them fail under Mojo::JSON (which uses the JSON::PP::Boolean provided by Perl core).
As a temporary fix, you can install Cpanel::JSON::XS and then Yancy will install successfully. I will fix this issue in the next release (instead of using true/false, I need to use 1/0, which is annoying...) and add a new Travis build to prevent regression (setting MOJO_NO_JSON_XS=1
will prevent Mojolicious from trying to use Cpanel::JSON::XS, which makes these tests fail even if that module is installed).
Thanks for the report!
This should be fixed in v1.028. If not, or if you have other problems, let me know. Thanks again!
I'm trying to install Yancy, but tests keep failing. Every test (it seems) in dbic.t is failing because it's getting 0 as a string, and expects to get 0 as a number.
Perhaps I'm missing a dependency that slipped under the rug?