0

I'm trying to start the openhab dashing project, but I'm still having the same error. When I try the dashing with the sample project everything starts perfect, but not with the OpenHab project.

user@server:~/dashboard$ dashing start
/usr/local/lib/ruby/gems/2.0.0/gems/backports-3.6.7/lib/backports/std_lib.rb:9:in `require': cannot load such file -- data_mapper (LoadError)
        from /usr/local/lib/ruby/gems/2.0.0/gems/backports-3.6.7/lib/backports/std_lib.rb:9:in `require_with_backports'
        from /home/jopo/dashboard/lib/settings.rb:1:in `<top (required)>'
        from /usr/local/lib/ruby/gems/2.0.0/gems/backports-3.6.7/lib/backports/std_lib.rb:9:in `require'
        from /usr/local/lib/ruby/gems/2.0.0/gems/backports-3.6.7/lib/backports/std_lib.rb:9:in `require_with_backports'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing/app.rb:157:in `block in require_glob'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing/app.rb:156:in `each'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing/app.rb:156:in `require_glob'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing/app.rb:166:in `<top (required)>'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing.rb:3:in `require'
        from /usr/local/lib/ruby/gems/2.0.0/gems/dashing-1.3.4/lib/dashing.rb:3:in `<top (required)>'
        from config.ru:1:in `require'
        from config.ru:1:in `block in <main>'
        from /usr/local/lib/ruby/gems/2.0.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `instance_eval'
        from /usr/local/lib/ruby/gems/2.0.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `initialize'
        from config.ru:1:in `new'
        from config.ru:1:in `<main>'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/rack/adapter/loader.rb:33:in `eval'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/rack/adapter/loader.rb:33:in `load'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/thin/controllers/controller.rb:182:in `load_rackup_config'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/thin/controllers/controller.rb:72:in `start'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/thin/runner.rb:200:in `run_command'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/lib/thin/runner.rb:156:in `run!'
        from /usr/local/lib/ruby/gems/2.0.0/gems/thin-1.6.4/bin/thin:6:in `<top (required)>'
        from /usr/local/bin/thin:23:in `load'
        from /usr/local/bin/thin:23:in `<main>'

Where do I need to search for the solution?

Jonas
  • 67
  • 1
  • 9

1 Answers1

0

It is missing a ruby gem. Try to install it with

sudo gem install datamapper
bogl
  • 1,864
  • 1
  • 15
  • 32
  • did it but no result. I installed the: libsqlite3-dev package with apt-get and also gem install data_mapper. But still the same error as above. – Jonas Jan 15 '16 at 23:35
  • How did you install openhab (package/gem/source)? How did you install dashing? – bogl Jan 16 '16 at 18:32
  • Can you check if dashing is using the same ruby installation as the one that responds in the shell (where you have installed data_mapper)? Your error log shows that ruby is located in /usr/local/bin . That is not where ruby gets installed by default with apt-get in Debian/Ubuntu. – bogl Jan 16 '16 at 18:54
  • I installed the dashing in my home/user directory. And created a new dashboard, After that I implemented the Openhab settings and files. The data_mapper I installed with the instructions: " sudo apt-get install libsqlite3-dev" and "gem install data_mapper". The ruby installation I did with the classic way with apt-get. – Jonas Jan 17 '16 at 11:04
  • When I remove or hide the settings.rb file, where the require 'data_mapper' is used. I can start the dashing/openhab dashboard. So I must be with data_mapper installation. Or there is maybe no sqlite:persistent.db availible? – Jonas Jan 17 '16 at 11:12
  • I realize that dashing is using `bundle` to manage the Gems. That is why it is searching in /usr/local/lib/ruby. Try to `cd` to where you have installed openhab-dashing, and run `bundle install`. – bogl Jan 17 '16 at 13:04