Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Net-Twitter CPAN distribution.

Report information
The Basics
Id: 48607
Status: resolved
Priority: 0/
Queue: Net-Twitter

People
Owner: MMIMS [...] cpan.org
Requestors: chezzabug [...] googlemail.com
Cc:
AdminCc:

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



Subject: Support for the Search API Retry-After header
Date: Tue, 11 Aug 2009 00:31:02 +0100
To: bug-Net-Twitter [...] rt.cpan.org
From: Richard Leach <chezzabug [...] googlemail.com>
Twitter API documentation suggests that applications that exceed rate limitations should pay attention to the "Retry-After" HTTP header: http://apiwiki.twitter.com/Rate-limiting The documentation for Net::Twitter (3.04006) doesn't seem to show how this can be done, if indeed Net::Twitter does expose this information. Please could support be added for this header, if it isn't already in this module. Many Thanks!
The Retry-After header should be available via the error thrown when on the offending call: my $nt = Net::Twitter->new(legacy => 0, ...); $r = eval { $nt->search(...) }; if ( $@ ) { my $retry_after = $@->http_response->header('retry-after'); ... } Hope this helps. -Marc