web3-eth 0.2.2 → 0.2.3

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: d83e37d8883b9c3f2f24ae5d618aac0ca4b55f5a
4
- data.tar.gz: c8f12035144eed30d9ae325899eb32e3e1f5b83e
3
+ metadata.gz: 94079e0002d2e9125fa24d5e1381ae5fbab23938
4
+ data.tar.gz: 13f0e31df3e61741546278b98af46817e3586888
5
5
  SHA512:
6
- metadata.gz: 0e0f2978e11073a94723cd6f3d7419c971b467137f82f8819af1afd9c2f92307c662d617be356d916ed6ce5ce5979dd4778de94b62f9920020e0f5b160693b50
7
- data.tar.gz: 9e62e9f999b7bb8c71dcb5da4a26e1c202df1f006655260a0a617692e92598b56efb1d93f6ebdd714fb33c3088bee36b3eeb83477e1035463ab24404bd04131b
6
+ metadata.gz: 808328c17db0c4e6c968edfed5e963fae41db63e7f0a98c105efa4b92660d7014b732776e30f1b961b5edbc560bc9a1601773fc7b521159a28667338bce19e12
7
+ data.tar.gz: afe7674f73ad40b545eff2d23a9f322d22318c834e6cdce78e88290e3deb19a2cc7e3ea18942dca5579b906bb9046768803878490311c3605c8126c4b831492a
data/README.md CHANGED
@@ -52,6 +52,32 @@ web3 = Web3::Eth::Rpc.new host: 'node.host.com',
52
52
  HTTP connection options are from [Ruby HTTP](https://ruby-doc.org/stdlib-2.4.2/libdoc/net/http/rdoc/Net/HTTP.html) plus additional optional property
53
53
  **rpc_path** - path to RPC interface.
54
54
 
55
+ For example, to connect to infura node, you need the following configuration:
56
+
57
+ ```ruby
58
+ web3 = Web3::Eth::Rpc.new host: 'mainnet.infura.io',
59
+ port: 443,
60
+ connect_options: {
61
+ open_timeout: 20,
62
+ read_timeout: 140,
63
+ use_ssl: true,
64
+ rpc_path: '/<YOUR INFURA PERSONAL KEY>'
65
+ }
66
+ ```
67
+
68
+ or to connect to Ropsten:
69
+
70
+
71
+ ```ruby
72
+ web3 = Web3::Eth::Rpc.new host: 'ropsten.infura.io',
73
+ port: 443,
74
+ connect_options: {
75
+ open_timeout: 20,
76
+ read_timeout: 140,
77
+ use_ssl: true
78
+ }
79
+ ```
80
+
55
81
  ### Calling eth interface
56
82
 
57
83
  ```
@@ -50,7 +50,7 @@ module Web3
50
50
  end
51
51
 
52
52
  def creates
53
- action['init'] && result['address']
53
+ action && result && action['init'] && result['address']
54
54
  end
55
55
 
56
56
  # suffix # 0xa1 0x65 'b' 'z' 'z' 'r' '0' 0x58 0x20 <32 bytes swarm hash> 0x00 0x29
@@ -1,5 +1,5 @@
1
1
  module Web3
2
2
  module Eth
3
- VERSION = "0.2.2"
3
+ VERSION = "0.2.3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: web3-eth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - studnev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-01-25 00:00:00.000000000 Z
11
+ date: 2018-01-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rlp