farcall 0.4.4 → 0.4.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 41e00a210ae71f229decaacf525acd0bf43c09cc
4
- data.tar.gz: 0ed79e622f5922cabfef6de22c59e8c663acebf7
3
+ metadata.gz: 94be337904ffb80e4699091e65d7ccd85c5abfbd
4
+ data.tar.gz: 267901a2112a6502d4f6226338eda4a326567452
5
5
  SHA512:
6
- metadata.gz: 38c7f1b48fa820506bd39d80bfbbd2a98c4ff6de2dd3accbe88b58f1021325e7c4e077e0d73cc1f6ca0c276f229fdec94b12d0f12a03dba7f10e2b07ead51d13
7
- data.tar.gz: 6414ec7bd8497f749f89ecbac3a8d6b8cf0c920f9517d605903370777b9a23da7a02b09f1ba5f65dd1c8810f9469dece2532452cc74443e4f6adedc244eda91a
6
+ metadata.gz: 281679347ac52ba8e630b36021982e98edb70571e1ccf4d80a486c15474a1a6439d95cae037f57a5571c97121be8acf43af035a1208dbe6b3b035e7fbe6c542f
7
+ data.tar.gz: 8d22d1ddfc96c928d9f9c4aa3cef2002d385feb4c44fcb62e82392419fffb696cb73a06c6ba55b82f9611678d7999686a591db0dfcb47c65ca13b301ab6318fa
@@ -147,7 +147,7 @@ module EmFarcall
147
147
 
148
148
  # Same as #on_command (compatibilty method)
149
149
  def on_remote_call &block
150
- on_command block
150
+ on_command &block
151
151
  end
152
152
 
153
153
  # Get the Farcall::RemoteInterface connnected to this endpoint. Any subsequent calls with
@@ -182,12 +182,14 @@ module EmFarcall
182
182
  end
183
183
  send_block ref: ref, result: result
184
184
 
185
- rescue
185
+ rescue Exception => e
186
186
  if @trace
187
187
  puts $!
188
188
  puts $!.backtrace.join("\n")
189
189
  end
190
- send_block ref: ref, error: { class: $!.class.name, text: $!.to_s }
190
+ error_data = { 'class' => e.class.name, 'text' => e.to_s }
191
+ e.respond_to?(:data) and error_data[:data] = e.data
192
+ send_block ref: ref, error: error_data
191
193
  end
192
194
 
193
195
  # :nodoc: important that this method is called from reactor thread only
@@ -1,3 +1,3 @@
1
1
  module Farcall
2
- VERSION = "0.4.4"
2
+ VERSION = "0.4.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: farcall
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.4
4
+ version: 0.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - sergeych
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-03 00:00:00.000000000 Z
11
+ date: 2016-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: hashie