[sf-perl] 406 Not Acceptable
friedman at highwire.stanford.edu
Tue Jul 14 16:17:04 PDT 2009
Aha. Thanks for pointing that out. I've got a very old copy of the
documentation here, but mostly I just couldn't imagine a desire for
that behavior. I suppose it makes more sense when you're sharing your
web-enabled client via CPAN and it can be used with a hundred
different versions of LWP. You'd want to know which version so you
could debug problems.
Mike Friedman | HighWire Press, Stanford Univ | friedman at highwire.stanford.edu
On Jul 14, 2009, at 2:20 PM, Michael C. Toren wrote:
> On Sat, Jul 11, 2009 at 10:19:32PM -0700, Michael Friedman wrote:
>> Hey, look at this undocumented feature!
>> Wow, this looks remarkably annoying. I wonder why the author did
>> It's obviously intentional, as it's been continuously in service from
>> at least version 2.36 to 5.829 (the latest).
> It's not only documented, it's remarkably handy. I can quickly set my
> User-Agent to the string "foobot/$VERSION ", which lets me announce
> only the version of my bot, but also the version of LWP it's pulling
> The documentation from 5.805 (the version that happens to be installed
> on the system I'm sending mail from) says:
> $ua->agent( $product_id )
> If the $product_id ends with space then the _agent() string is
> appended to it.
> and gives the example:
> $ua->agent('Checkbot/0.4 ' . $ua->_agent);
> $ua->agent('Checkbot/0.4 '); # same as above
> SanFrancisco-pm mailing list
> SanFrancisco-pm at pm.org
More information about the SanFrancisco-pm