After removing $ sign before sequel, the code passes. Here is the code that 
works:

     Ruote::Sequel.create_table(sequel, true, 'ruote_docs') unless 
ActiveRecord::Base.connection.table_exists? 'ruote_docs'

In rails console, there is the deprecation message about storage in 
ruote-sequel:

SEQUEL DEPRECATION WARNING: Symbol#desc is deprecated and will be removed 
in Sequel 4.0.  Please use Sequel.desc instead, or Sequel.extension(:core_ex
tensions) to continue using it.
C:/Ruby193/lib/ruby/gems/1.9.1/gems/sequel-3.48.0/lib/sequel/deprecated.rb:67:in
 
`block (3 levels) in deprecated_module'
C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruote-sequel-2.3.0/lib/ruote/sequel/storage.rb:413:in
 
`prepare_cache'
C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruote-sequel-2.3.0/lib/ruote/sequel/storage.rb:345:in
 
`begin_step'
C:/Ruby193/lib/ruby/gems/1.9.1/bundler/gems/ruote-2048bc6ad7c6/lib/ruote/worker.rb:239:in
 
`begin_step'
C:/Ruby193/lib/ruby/gems/1.9.1/bundler/gems/ruote-2048bc6ad7c6/lib/ruote/worker.rb:247:in
 
`step'
C:/Ruby193/lib/ruby/gems/1.9.1/bundler/gems/ruote-2048bc6ad7c6/lib/ruote/worker.rb:109:in
 
`run'
C:/Ruby193/lib/ruby/gems/1.9.1/bundler/gems/ruote-2048bc6ad7c6/lib/ruote/worker.rb:120:in
 
`block in run_in_thread'

This deprecation message keeps popping up in rails console screen and seems 
never stopping. 

On Wednesday, June 19, 2013 11:00:13 PM UTC-5, John Mettraux wrote:
>
>
> On Wed, Jun 19, 2013 at 08:42:23PM -0700, emc_lab wrote: 
> > Changed to : 
> > 
> > Ruote::Sequel.create_table($sequel, true, 'ruote_docs') unless 
> > ActiveRecord::Base.connection.table_exists? 'ruote_docs' 
> > 
> > Here is another error which is caused by: 
> > 
> > m = re_create ? :create_table! : :create_table? 
> > 
> > 
> > in storage.rb. 
> > 
> > 
> > 
> C:/Ruby193/lib/ruby/gems/1.9.1/gems/ruote-sequel-2.3.0/lib/ruote/sequel/storage.rb:46:in
>  
>
> > `create_table': undefined method `create_table!' for nil:NilC 
> > lass (NoMethodError) 
> >         from 
> > C:/D/code/rails_proj/ruote_in_rails/config/initializers/ruote.rb:15:in 
>
> Hello, 
>
> if we look at more of the code (and especially at the line where the error 
> happens, not at the previous line): 
>
>
> ``` 
>   def self.create_table(sequel, re_create=false, table_name='documents') 
>
>     m = re_create ? :create_table! : :create_table? 
>
>     sequel.send(m, table_name.to_sym) do # <=========== error happens here 
>       # ... 
>     end 
>     # ... 
>   end 
> ``` 
>
> The error says "undefined method `create_table!' for nil:NilClass 
> (NoMethodError)". 
>
> That means "sequel" is nil. 
>
> You are passing nil in $sequel. 
>
> Please read error messages it will make you a better programmer. 
>
>
> Best regards, 
>
> -- 
> John Mettraux   -   http://lambda.io/jmettraux 
>
>

-- 
-- 
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"ruote" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to