Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

ambition: Less than and greater than cause stack trace

#99

When constructing a query using something like the following, I receive a stack trace, after calling to_sql or to_hash on the query object:

@@@ Ruby Property.select { |p| p.rent >= 300 }


A similar query, such as the following does not produce a stack trace: 


@@@ Ruby Property.select { |p| p.rent > 300 }

And here's that stack trace:

RuntimeError: No reflection rent' found on Property from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/processor.rb:63:inextract_includes' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/where.rb:147:in translation' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/where.rb:42:inprocess_call' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:241:in send' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:241:inprocess' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:299:in error_handler' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:240:inprocess' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/processor.rb:28:in process_proc' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:241:insend' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:241:in process' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:299:inerror_handler' from /var/lib/gems/1.8/gems/ParseTree-2.0.1/lib/sexp_processor.rb:240:in process' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/processor.rb:45:into_s' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/query.rb:70:in keyed_clauses' from (irb):56:ininject' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/query.rb:68:in each' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/query.rb:68:ininject' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/query.rb:68:in keyed_clauses' from ./script/../config/../config/../vendor/plugins/ambition-0.1.4/lib/ambition/query.rb:55:into_sql'

Reported by Louis Rose · August 30th, 2007 @ 01:55 PM

State: resolved
Milestone: none
Assigned to: Chris Wanstrath Chris Wanstrath

Activity

  1. Chris Wanstrath
    Chris Wanstrath
    • State changed from new to resolved

    Crap!

    Fixed in http://projects.require.errthebl...

    Just pushed out the 0.1.5 gem, expect it soon. Thanks!

    August 30th, 2007 @ 01:59 PM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.