18F / open-data-maker

make it easy to turn a lot of potentially large csv files into easily accessible open data
Other
200 stars 135 forks source link

NR error: "Stretchy::Errors::ValidationError" in QueryBuilder::search_location #266

Closed yozlet closed 8 years ago

yozlet commented 8 years ago

New Relic example. Frequency: 3 times from Jan 1 to Jan 7.

Stack trace:

…0/gems/stretchy-0.4.7/lib/stretchy/utils/validation.rb:   16:in `validate!'
…gems/stretchy-0.4.7/lib/stretchy/filters/geo_filter.rb:   22:in `initialize'
…stretchy-0.4.7/lib/stretchy/builders/filter_builder.rb:   33:in `new'
…stretchy-0.4.7/lib/stretchy/builders/filter_builder.rb:   33:in `add_geo'
…/stretchy-0.4.7/lib/stretchy/builders/where_builder.rb:   45:in `add_geo'
…ms/stretchy-0.4.7/lib/stretchy/clauses/where_clause.rb:  135:in `geo'         /home/vcap/app/lib/data_magic/query_builder.rb:  132:in `search_location'
         /home/vcap/app/lib/data_magic/query_builder.rb:   30:in `generate_squery'
         /home/vcap/app/lib/data_magic/query_builder.rb:   13:in `from_params'
                       /home/vcap/app/lib/data_magic.rb:   69:in `search'
                      /home/vcap/app/app/controllers.rb:   53:in `block (2 levels) in <top (required)>'
(eval):225:in `block in call'
(eval):214:in `catch'

Refers to this line:

squery = squery.geo('location', distance: distance, lat: location[:lat], lng: location[:lon])

(May be related to #265, somehow? But the occurrences of this error happen at completely different times)

yozlet commented 8 years ago

Fixed by #286.