Closed puck closed 7 months ago
The problem here is you are using JSON::XS, which is not interface-compatible with JSON::PP and Cpanel::JSON::XS. I believe there were plans to drop all use of JSON::XS via JSON::MaybeXS, but that hasn't happened yet. Nevertheless, I would highly recommend you switch: https://metacpan.org/pod/Perl::Critic::Policy::Community::DiscouragedModules#JSON::XS
Glad to see you're using JSON::Schema::Modern! I haven't heard of many people using it yet (or maybe they're just silently content?) :)
Oh, interesting. Would it be possible to also have JSON::MaybeXS know it can't use JSON::XS if incompatible parameters are passed in? The error message was a bit "huh?!" (I can raise a bug report against JSON::MaybeXS as well, but you'll see it there as well!)
They might be silently content, but I'm about to ping you on IRC about some behaviour that was me confused. :)
This was fixed in version 0.578 by removing the possibility of JSON::XS being used as a json backend.
Hey,
I'm getting:
If I look in JSON::XS there is no method called allow_bignum. If I remove allow_bignum from /usr/share/perl5/JSON/Schema/Modern.pm then I can load my schema (okay, let's by honest, I can get to the next error).
This on Debian Unstable versions are:
Which all appear to be the latest versions available via CPAN.
Cheers, Andrew