Beefy Boxes and Bandwidth Generously Provided by pair Networks kudra
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^2: Should LWP warn about wrong Content-Length? (it does)

by vsespb (Hermit)
on May 30, 2013 at 08:42 UTC ( #1036003=note: print w/ replies, xml ) Need Help??


in reply to Re: Should LWP warn about wrong Content-Length? (it does)
in thread Should LWP warn about wrong Content-Length?

warn "Content-Length header value was wrong, fixed"; warn "Content-Length set when there is no content, fixed";
I saw this code, but looks like it's request headers, not response header. Besides in my example, there is no warnings.
'GET' implies very old version of LWP
GET just uses last version of LWP, installed on the box. No?
Also I actually experience this behaviour in my normal code, without GET tool.


Comment on Re^2: Should LWP warn about wrong Content-Length? (it does)
Re^3: Should LWP warn about wrong Content-Length? (it does)
by Anonymous Monk on May 30, 2013 at 09:01 UTC

    I saw this code, but looks like it's request headers, not response header. Besides in my example, there is no warnings.

    Well :) now you know your next course of action, submit a bug report if you think its important

    OTOH, a warning seems like a clumsy way to communicate this -- sure its better than nothing, but not by much

    GET just uses last version of LWP, installed on the box. No?

    I think so yeah, but its not installed by default anymore ... which version do you have, the latest available?

      warning seems like a clumsy way to communicate this
      For request it's probably OK. Because wrong Content-Length in request is must be programmer mistake. But wrong Content-Length in response is something programmer cannot control.

      For response there are existing ways to report problem, like: HTTP 500 with 'Client-Warning'=> 'Internal response' header. Or 'X-Died' header (without changing http response code, i.e. it can be 200 OK)

      which version do you have
      perl -MLWP -e 'print LWP->VERSION' 6.05

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1036003]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (8)
As of 2014-04-17 01:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (437 votes), past polls