Days Since It Rained


The answer is wrong!
DSIR is only as accurate as the data it uses. The weather history data comes from the airport nearest a location (via Weather Underground). These are not always major airports, and they don't always record precipitation data. For example, Palo Alto Airport does not record precipitation data at all. For more accurate results, try searching for a nearby major airport.
Because the history data comes from airports the results may not be accurate for you if the nearest airport is far away or does not record accurate data. Also note that not every rain event results in measurable amounts of rain and these won't show up in DSIR.

Is snow included?
Snow is counted as precipitation by airports and reported as equivalent inches of rain.

What's going on behind the scenes?
The search query is first converted to a geographic location by the Google Maps Geocoding API . Then DSIR checks with Weather Underground to find the nearest airport. This step actually requests the page for the current conditions from WU and uses a regular expression to parse out an airport code.
Finally, DSIR requests weather history from Weather Underground for that airport and searches for recorded precipitation. (Here, for example, is one month of history data for Oakland Airport.) DSIR retrieves one year of history data at a time using WU's custom search URL. DSIR will search back a maximum of five years looking for precipitation.
If no recorded precipiation is found (because not all airports record precipitation), DSIR searches instead for rain "events". In this case DSIR can't say how much it rained, only that someone recorded rain on a given day.

Who made DSIR?
DSIR was made by Matt Davis, aka jiffyclub. Feel free to get in touch.

Where is DSIR running?
DSIR runs on Heroku. It's a Python 3 application built primarily using Flask, Jinja, and Requests. (Plus, of course, the wonderful Python Standard Library.) The small bit of client code uses jQuery and Handlebars. I got a headstart on the HTML and CSS with HTML5 Boilerplate.