Skip to content

Instantly share code, notes, and snippets.

@djwonk
Created September 14, 2008 19:42
Show Gist options
  • Save djwonk/10757 to your computer and use it in GitHub Desktop.
Save djwonk/10757 to your computer and use it in GitHub Desktop.
bayes:herb david$ merb -i
~ Loaded DEVELOPMENT Environment...
~ loading gem 'merb_datamapper' ...
~ loading gem 'dm-core' ...
~ Merb::Orms::DataMapper::Connect block.
~ Connecting to database...
~ Checking if we need to use DataMapper sessions
~ Merb::Orms::DataMapper::Connect complete
~ Compiling routes...
~ Starting Merb server listening at 0.0.0.0:4000
irb(main):001:0> g = Goal.new
=> #<Goal id=nil slug=nil>
irb(main):002:0> g.save
uri_string : #<struct DataObjects::URI scheme="mysql", user="david", password=nil, host="localhost", port=nil, specified_port=nil, path="/herb_development", query="encoding=utf8&socket=/opt/local/var/run/mysql5/mysqld.sock", fragment=nil>
~ private method `scan' called for #<DataObjects::URI:0x1130e88>
NoMethodError: private method `scan' called for #<DataObjects::URI:0x1130e88>
from /usr/local/lib/ruby/gems/1.8/gems/addressable-1.0.4/lib/addressable/uri.rb:77:in `parse'
from /usr/local/lib/ruby/gems/1.8/gems/data_objects-0.9.6/lib/data_objects/uri.rb:8:in `parse'
from /usr/local/lib/ruby/gems/1.8/gems/data_objects-0.9.6/lib/data_objects/connection.rb:12:in `new'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:147:in `create_connection'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:170:in `with_connection'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:90:in `execute'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:26:in `create'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:15:in `each'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/adapters/data_objects_adapter.rb:15:in `create'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/repository.rb:51:in `create'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/resource.rb:555:in `hookable__create_nan_before_advised'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:294:in `create'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:292:in `catch'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:292:in `create'
from /usr/local/lib/ruby/gems/1.8/gems/dm-core-0.9.6/lib/dm-core/resource.rb:281:in `hookable__save_nan_before_advised'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:294:in `save'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:292:in `catch'
from /usr/local/lib/ruby/gems/1.8/gems/extlib-0.9.7/lib/extlib/hook.rb:292:in `save'
from (irb):2irb(main):003:0>
class Goal
include DataMapper::Resource
# ==== Properties
property :id, Serial
property :slug, String
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment