ethereum 0.5.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8f1177d726d56bdd0d7d0979824d067b4da1aff9
4
- data.tar.gz: 091280255725556472bedad0b99d1f9151070585
3
+ metadata.gz: 9a05ae654690a826058ea550ff9c8a1455f69b6d
4
+ data.tar.gz: b330ea17618b1f59f8588f924d7f506ce4a267ac
5
5
  SHA512:
6
- metadata.gz: e5bea3d33b137ee29571bb3f961996c307a1e8ef699455eee4abd9d0702bb1b42675dc2f4a03c4b99981f0bc723a7d56087709b1ad62d8b92f4254484bd87b5e
7
- data.tar.gz: f4250eaec615d1354b6bc445cebced74976db3338c6bcd075f0e7dc59022ccc939f7443111408dde98d5fd1af1eb24987ec4499f5d978b97503849170452b7a2
6
+ metadata.gz: 61ffb0a9c3cc798725d910a9dd1566f790ee7edc0e8abf43680ad44cd35f713bcfb4eae3f1d74cc8dc5b287588080097fe431432d0a30cbbebf4c2a20cc8961d
7
+ data.tar.gz: cdf551d2340dbdbfbe6ad3424a1e28feb8d0b52ccedf5cab8b55c9d749418760b2fc170922af8690a11addb93fe5b4512b5b8784f76af968d3ad582d7acc99d3
@@ -43,7 +43,7 @@ module Ethereum
43
43
  end
44
44
  end
45
45
  deploy_payload = deploy_code + deploy_arguments
46
- deploytx = connection.send_transaction({from: self.sender, gas: self.gas, gasPrice: self.gas_price, data: deploy_payload})["result"]
46
+ deploytx = connection.send_transaction({from: self.sender, gas: self.gas, gasPrice: self.gas_price, data: "0x" + deploy_payload})["result"]
47
47
  instance_variable_set("@deployment", Ethereum::Deployment.new(deploytx, connection))
48
48
  end
49
49
 
@@ -169,10 +169,10 @@ module Ethereum
169
169
  arg_types.zip(args).each do |arg|
170
170
  payload << formatter.to_payload(arg)
171
171
  end
172
- raw_result = connection.call({to: self.address, from: self.sender, data: payload.join()})["result"]
172
+ raw_result = connection.call({to: self.address, from: self.sender, data: "0x" + payload.join()})["result"]
173
173
  formatted_result = fun.outputs.collect {|x| x.type }.zip(raw_result.gsub(/^0x/,'').scan(/.{64}/))
174
174
  output = formatted_result.collect {|x| formatter.from_payload(x) }
175
- return {data: payload.join(), raw: raw_result, formatted: output}
175
+ return {data: "0x" + payload.join(), raw: raw_result, formatted: output}
176
176
  end
177
177
 
178
178
  define_method call_function_name do |*args|
@@ -195,7 +195,7 @@ module Ethereum
195
195
  arg_types.zip(args).each do |arg|
196
196
  payload << formatter.to_payload(arg)
197
197
  end
198
- txid = connection.send_transaction({to: self.address, from: self.sender, data: payload.join(), gas: self.gas, gasPrice: self.gas_price})["result"]
198
+ txid = connection.send_transaction({to: self.address, from: self.sender, data: "0x" + payload.join(), gas: self.gas, gasPrice: self.gas_price})["result"]
199
199
  return Ethereum::Transaction.new(txid, self.connection, payload.join(), args)
200
200
  end
201
201
 
@@ -1,3 +1,3 @@
1
1
  module Ethereum
2
- VERSION = "0.5.0"
2
+ VERSION = "0.5.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ethereum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - DigixGlobal Pte Ltd (https://dgx.io)
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-13 00:00:00.000000000 Z
11
+ date: 2016-05-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler