Skip Menu |

This queue is for tickets about the Dezi-Client CPAN distribution.

Report information
The Basics
Id: 94700
Status: resolved
Priority: 0/
Queue: Dezi-Client

People
Owner: Nobody in particular
Requestors: CRZEDPSYC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Dezi::Doc fails to accept the mtime array from the server
Reference ["1394567197"] did not pass type constraint "Int" (in $args->{"mtime"}) at /home/ddgc/perl5/perlbrew/perls/perl-5.16.2/lib/site_perl/5.16.2/Dezi/Response.pm line 109 "Int" is a subtype of "Num" "Num" is a subtype of "LaxNum" "LaxNum" is a subtype of "Str" "Str" is a subtype of "Value" Reference ["1394567197"] did not pass type constraint "Value" (in $args->{"mtime"}) "Value" is defined as: (defined($_) and not ref($_)) Sample data from the server: http://ix.io/bF1 Reverting to Dezi::Client 0.002002 fixes the problem.
After chatting on IRC, we discovered that the 'mtime' field was getting auto-vivified through the UndefinedMetaTags indexer configuration option, and conflicting with the reserved field name. The way to set the mtime explicitly from a client is via the X-SOS-Last-Modified HTTP header: https://metacpan.org/pod/Search::OpenSearch::Server#do_rest_api-request-response-path The reserved fields are described here: http://dezi.org/2013/02/13/reserved-fields/ The 0.3.0 Dezi::Client release revealed this issue only because it now has real type constraint checking on attributes via Moo. The config issue was already present; now the client's strict checking just showed it.