I needed a very very very simple Twitter plugin for wordpress, just to show my latest tweet. I found GetMyTweets to be just simple enough. Then I started to get some warnings, and reflexively hit the Google.
But to my surprise, doing a query on “getmytweets” on google got me this:

I recently had a couple of warnings with the GetMyTweets wordpress plug-in. These weren’t the same warnings, but you’ll get the gist of it:
Warning: XMLReader::open()
[function.XMLReader-open]: php_network_getaddresses:
getaddrinfo failed:
Name or service not known in
/blah/getMyTweets.php on line 38
Warning: XMLReader::open(
http://twitter.com/statuses/user_timeline/joshkim.xml?count=1)
[function.XMLReader-open]: failed to open stream:
No such file or directory in /blah/getMyTweets.php on line 38
Warning: XMLReader::open() [function.XMLReader-open]:
Unable to open source data in /blah/getMyTweets.php on line 38
Warning: XMLReader::read()
[function.XMLReader-read]: Load Data before trying to read in
/blah/getMyTweets.php on line 39
(Note to self: Fix <pre><code> later. Sorry about that, to everyone who got this post multiple times.)
Obviously, the problem is with being unable to grab the xml provided by Twitter. Due to it’s ridiculous open architecture, I don’t blame Twitter when it chokes now and then (and not as much as it did when the whole Fail Whale was in vogue). For now, I just decided to hide it. Just append the following at the top of getMyTweets.php, just like with any other PHP warnings.
ini_set("display_errors", 0);
I’m fine with this fix, because I made the title for “Recent Tweets” link up to my twitter page anyway.
Now back to Rails.