dkubb / axiom

Simplifies querying of structured data using relational algebra
https://github.com/dkubb/axiom
MIT License
459 stars 22 forks source link

undefined local variable or method `include_comparison_methods' #53

Closed acook closed 10 years ago

acook commented 10 years ago

Error when attempting to use Axiom:

/Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/equalizer.rb:18:in `initialize': undefined local variable or method `include_comparison_methods' for #<Axiom::Equalizer:0x007fa94bd5d698> (NameError)
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/operation/binary.rb:6:in `new'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/operation/binary.rb:6:in `<module:Binary>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/operation/binary.rb:5:in `<module:Operation>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/operation/binary.rb:4:in `<module:Axiom>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom/support/operation/binary.rb:3:in `<top (required)>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom.rb:90:in `require'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/axiom-0.1.1/lib/axiom.rb:90:in `<top (required)>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/rom-relation-0.1.2/lib/rom-relation.rb:10:in `require'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/rom-relation-0.1.2/lib/rom-relation.rb:10:in `<top (required)>'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/rom-0.1.2/lib/rom.rb:4:in `require'
        from /Users/acook/.rvm/gems/ruby-2.1.1@rom/gems/rom-0.1.2/lib/rom.rb:4:in `<top (required)>'
        from ./run_me.rb:6:in `require'
        from ./run_me.rb:6:in `<main>'

Sample project to reproduce bug: https://gist.github.com/acook/dbaa454f21681b4d27cd

solnic commented 10 years ago

sorry about this; it's fixed on edge, I'll push a release...soon

acook commented 10 years ago

Ah, using head versions of everything (rom, axiom, axiom-memory-adapter) does work. Looking forward to updated released gems.

dkubb commented 10 years ago

@solnic was it a bug in axiom, or somewhere else?

acook commented 10 years ago

@dkubb It looks like a bug in Axiom's integration with Equalizer. It seems it was fixed in this commit 4 months ago, but the latest released code (on January 2014) doesn't seem to include the change.

solnic commented 10 years ago

It wasn't a bug; equalizer had a breaking change and that's it.