rabbit-shocker/rabbit

Unable to load svg image

Closed this issue · 9 comments

https://github.com/colindean/talks/tree/master/lightning/rubocop/rubocop.md

[colin@kid rubocop (master)]$ rabbit rubocop.md
[WARNING]
./bark.svg: Unrecognized image file format
[WARNING]
Rabbit::ImageFileDoesNotExistError: no such file: bark.svg
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:629:in `image_element'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/background-image-toolkit/background-image-toolkit.rb:21:in `apply_background_image_property'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/body-background-image/body-background-image.rb:6:in `block (3 levels) in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/body-background-image/body-background-image.rb:5:in `each'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/body-background-image/body-background-image.rb:5:in `block (2 levels) in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:439:in `call'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:439:in `match'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/body-background-image/body-background-image.rb:1:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `instance_eval'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/searcher.rb:24:in `in_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:259:in `apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:323:in `include_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/default/default.rb:35:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `instance_eval'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/searcher.rb:24:in `in_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:259:in `apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:323:in `include_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/nari/nari.rb:58:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `instance_eval'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:260:in `block in apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/searcher.rb:24:in `in_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/applier.rb:259:in `apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/theme/manager.rb:22:in `apply'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:657:in `_apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:305:in `apply_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:321:in `reload_theme'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:335:in `block in parse'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:726:in `keep_index'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/canvas.rb:330:in `parse'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/frame.rb:56:in `parse'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/command/rabbit.rb:702:in `parse'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/command/rabbit.rb:864:in `do_display'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/command/rabbit.rb:51:in `run'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/lib/rabbit/command/rabbit.rb:29:in `run'
/Users/colin/.rvm/gems/ruby-2.1.3/gems/rabbit-2.1.3/bin/rabbit:22:in `<top (required)>'
/Users/colin/.rvm/gems/ruby-2.1.3/bin/rabbit:23:in `load'
/Users/colin/.rvm/gems/ruby-2.1.3/bin/rabbit:23:in `<main>'
/Users/colin/.rvm/gems/ruby-2.1.3/bin/ruby_executable_hooks:15:in `eval'
/Users/colin/.rvm/gems/ruby-2.1.3/bin/ruby_executable_hooks:15:in `<main>'

gem list

atk (2.2.2, 2.1.0)
bigdecimal (1.2.4)
bundler (1.7.3)
bundler-unload (1.0.2)
cairo (1.12.9, 1.12.8)
coderay (1.1.0)
eventmachine (1.0.3)
executable-hooks (1.3.2)
faraday (0.9.0)
gdk_pixbuf2 (2.2.2, 2.1.0)
gem-wrappers (1.2.4)
gettext (3.1.4, 3.1.1)
gio2 (2.1.0)
glib2 (2.2.2, 2.1.0)
gtk2 (2.1.0)
hikidoc (0.0.6)
http_parser.rb (0.5.3)
io-console (0.4.2)
json (1.8.1)
kramdown (1.3.2)
locale (2.1.0)
mime-types (2.1)
mini_portile (0.5.2)
minitest (4.7.5)
multipart-post (2.0.0)
nokogiri (1.6.1)
oauth (0.4.7)
pango (2.1.0)
pkg-config (1.1.5)
poppler (2.1.0)
psych (2.0.5)
rabbit (2.1.3, 2.1.2)
rabbiter (2.0.1)
rake (10.1.0)
rdoc (4.1.0)
rdtool (0.6.38)
rsvg2 (2.1.0)
rttool (1.0.3.0)
rubygems-bundler (1.4.4)
rvm (1.11.3.9)
simple_oauth (0.1.9)
test-unit (2.1.3.0)
text (1.3.0, 1.2.3)
twitter-stream (0.1.16)
twitter_oauth (0.4.94)

A side effect is that it seems to cause weirdness to the theme, too.

If it helps to understand the problem I tried only the 'rubocop folder' out of everything without any ruby version forcing and with ruby 2.1.3 and rabbit 2.1.3 I had no problem

A possible attempt might be to remove or modify the files Gemfile.lock and .ruby-version

Updated .ruby-version to 2.1.3. Got rid of the lock and bombed the gem set.

bundle install and I get the same gobject-introspection install problem that I had on Ruby 2.1.2 (See ruby-gnome/ruby-gnome#259).

I removed rabbiter from my Gemfile and it proceeded, remembering that I’d done something similar previously when gobject-introspection was messing up.

However, I still get the same error as above when running rabbit rubocop.md.

Another possible attempt might be to create a .ruby-version file into the 'slide' folder (ie rubocop directory in this case). In my machine rvm seem to set different path when the file is into the final directory or the file is into the root directory. With the file into the root directory ruby is set to the correct version but I cannot launch any application from the bin folder (command not found). Create a .ruby-version file into the final folder solve the problem. Apart this issue I han no problem for the slide with ruby 2.1.3, rabbit 2.1.3 and rabbiter 2.0.2 installed

I should mention that I’m on OSX.

Maybe I’m missing some dependency in a system library installed via Homebrew?

I'm on Linux.
it seems that you have two versions of Rabbit installed in your system, is a willed thing?
if I were in your situation I would try to remove the 2.1.2 version, update all the gem and try again (of course if there are no problems with other installations)

I did some other tests but with the same results.
For the moment I have exhausted my ideas as far I can.
Not being an expert on OSX I leave the area to other experts ;)
Sorry for not having helped @colindean in his problem.

kou commented

I hope that this has been solved the latest version.