<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Python library for the foursquare API</title>
	<atom:link href="http://ismaild.com/foursquare-api-python/feed/" rel="self" type="application/rss+xml" />
	<link>http://ismaild.com/foursquare-api-python/</link>
	<description>Peering over the Edge of Tech,Life &#38; Politics....</description>
	<lastBuildDate>Mon, 07 Dec 2009 21:41:01 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: rumpl</title>
		<link>http://ismaild.com/foursquare-api-python/comment-page-1/#comment-272</link>
		<dc:creator>rumpl</dc:creator>
		<pubDate>Mon, 07 Dec 2009 21:41:01 +0000</pubDate>
		<guid isPermaLink="false">http://ismaild.com/?p=380#comment-272</guid>
		<description>Hey,

(alright, this is my second try, this time I am going to save before trying to post).
I started playing with your little wrapper and it&#039;s really nice.

One thing tho : 
Let&#039;s take get_cities() for example. I cant just do :
for city in api.get_cities():
  print city[&quot;name&quot;]

Because get_cities doesn&#039;t return a list of cities, but a dictionary with one key &quot;cities&quot; whose value is the list of cities. So, the way the things are right now, I must do :
c = api.get_cities()
for city in c[&quot;cities&quot;]:
  print city[&quot;name&quot;]

And I find it a little awkward...

Is there a particular reason why you have done things this way or we could hope for a version where get_cities (or any other method that is supposed to return a list) will actually return a list ?

Cheers.</description>
		<content:encoded><![CDATA[<p>Hey,</p>
<p>(alright, this is my second try, this time I am going to save before trying to post).<br />
I started playing with your little wrapper and it&#8217;s really nice.</p>
<p>One thing tho :<br />
Let&#8217;s take get_cities() for example. I cant just do :<br />
for city in api.get_cities():<br />
  print city["name"]</p>
<p>Because get_cities doesn&#8217;t return a list of cities, but a dictionary with one key &#8220;cities&#8221; whose value is the list of cities. So, the way the things are right now, I must do :<br />
c = api.get_cities()<br />
for city in c["cities"]:<br />
  print city["name"]</p>
<p>And I find it a little awkward&#8230;</p>
<p>Is there a particular reason why you have done things this way or we could hope for a version where get_cities (or any other method that is supposed to return a list) will actually return a list ?</p>
<p>Cheers.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic Page Served (once) in 1.459 seconds -->
