cns 0.2.1 → 0.2.6

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
  SHA256:
3
- metadata.gz: 439f5efec89d8112201e07fdd0221ba66ab91c4c9bd2b0226f5758e5cfab3283
4
- data.tar.gz: 37b7e4c60c173d462c0597b87b57457ed61dc50e1a649c6c73d033521f441762
3
+ metadata.gz: 317da1b5cfb582d361f66b4a2be005ba8d222d373abc2bd5a094b7737510105c
4
+ data.tar.gz: 06eab4a14ba9fad076b0ca394083c4dffad80cf29db32fe4ab8d8f362d6f49c4
5
5
  SHA512:
6
- metadata.gz: c6304f5f565c63d5056329692baa00321b2baed18dec2fb2078c2725dc642f348f161891d28624818fa497a8e8e8802a07ad275ae3d22c9e22a51a9b51e7d9d8
7
- data.tar.gz: '06081e978f7166ad78292a8702f1c14843cea67413dd46a8a87737d7bee4cfe09e2a1655e9090279d1dbb2815f638537d3098fd2b59c304711e9125eb54d3b60'
6
+ metadata.gz: 161f041ca13c145698640dce514d76134e25fa12c7f76bf1e9050338543b2beb67cc80382afe6f30d01ebbac92ff1c0aee2c0d293165cb8141a25ce9ef09672c
7
+ data.tar.gz: 2e4b3692c305d8389f16e9499bb6ff7fde49dedcc5667bb1b2ea17403285422597d12ceca30b2c0f3cc8857e7884db03f9746c123cc8c4bc832294b612da0f8e
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cns (0.2.1)
4
+ cns (0.2.6)
5
5
  curb
6
6
  faraday
7
7
  google-cloud-bigquery
@@ -12,41 +12,51 @@ GEM
12
12
  specs:
13
13
  addressable (2.7.0)
14
14
  public_suffix (>= 2.0.2, < 5.0)
15
- ast (2.4.1)
15
+ ast (2.4.2)
16
16
  backport (1.1.2)
17
17
  benchmark (0.1.1)
18
- concurrent-ruby (1.1.7)
18
+ concurrent-ruby (1.1.8)
19
19
  curb (0.9.11)
20
20
  declarative (0.0.20)
21
- declarative-option (0.1.0)
22
21
  e2mmap (0.1.0)
23
- faraday (1.3.0)
22
+ faraday (1.4.2)
23
+ faraday-em_http (~> 1.0)
24
+ faraday-em_synchrony (~> 1.0)
25
+ faraday-excon (~> 1.1)
24
26
  faraday-net_http (~> 1.0)
27
+ faraday-net_http_persistent (~> 1.1)
25
28
  multipart-post (>= 1.2, < 3)
26
- ruby2_keywords
27
- faraday-net_http (1.0.0)
28
- google-api-client (0.52.0)
29
+ ruby2_keywords (>= 0.0.4)
30
+ faraday-em_http (1.0.0)
31
+ faraday-em_synchrony (1.0.0)
32
+ faraday-excon (1.1.0)
33
+ faraday-net_http (1.0.1)
34
+ faraday-net_http_persistent (1.1.0)
35
+ google-apis-bigquery_v2 (0.12.0)
36
+ google-apis-core (~> 0.1)
37
+ google-apis-core (0.3.0)
29
38
  addressable (~> 2.5, >= 2.5.1)
30
- googleauth (~> 0.9)
39
+ googleauth (~> 0.14)
31
40
  httpclient (>= 2.8.1, < 3.0)
32
41
  mini_mime (~> 1.0)
33
42
  representable (~> 3.0)
34
43
  retriable (>= 2.0, < 4.0)
35
44
  rexml
36
- signet (~> 0.12)
37
- google-cloud-bigquery (1.25.0)
45
+ signet (~> 0.14)
46
+ webrick
47
+ google-cloud-bigquery (1.31.0)
38
48
  concurrent-ruby (~> 1.0)
39
- google-api-client (~> 0.47)
49
+ google-apis-bigquery_v2 (~> 0.1)
40
50
  google-cloud-core (~> 1.2)
41
51
  googleauth (~> 0.9)
42
52
  mini_mime (~> 1.0)
43
- google-cloud-core (1.5.0)
53
+ google-cloud-core (1.6.0)
44
54
  google-cloud-env (~> 1.0)
45
55
  google-cloud-errors (~> 1.0)
46
- google-cloud-env (1.4.0)
56
+ google-cloud-env (1.5.0)
47
57
  faraday (>= 0.17.3, < 2.0)
48
- google-cloud-errors (1.0.1)
49
- googleauth (0.14.0)
58
+ google-cloud-errors (1.1.0)
59
+ googleauth (0.16.2)
50
60
  faraday (>= 0.17.3, < 2.0)
51
61
  jwt (>= 1.4, < 3.0)
52
62
  memoist (~> 0.16)
@@ -55,64 +65,64 @@ GEM
55
65
  signet (~> 0.14)
56
66
  httpclient (2.8.3)
57
67
  jaro_winkler (1.5.4)
58
- jwt (2.2.2)
59
- kramdown (2.3.0)
68
+ jwt (2.2.3)
69
+ kramdown (2.3.1)
60
70
  rexml
61
71
  kramdown-parser-gfm (1.1.0)
62
72
  kramdown (~> 2.0)
63
73
  kwalify (0.7.2)
64
74
  memoist (0.16.2)
65
- mini_mime (1.0.2)
66
- mini_portile2 (2.5.0)
75
+ mini_mime (1.1.0)
76
+ mini_portile2 (2.5.3)
67
77
  multi_json (1.15.0)
68
78
  multipart-post (2.1.1)
69
- nokogiri (1.11.1)
79
+ nokogiri (1.11.6)
70
80
  mini_portile2 (~> 2.5.0)
71
81
  racc (~> 1.4)
72
82
  os (1.1.1)
73
83
  parallel (1.20.1)
74
- parser (2.7.2.0)
84
+ parser (3.0.1.1)
75
85
  ast (~> 2.4.1)
76
- psych (3.3.0)
86
+ psych (3.3.2)
77
87
  public_suffix (4.0.6)
78
88
  racc (1.5.2)
79
89
  rainbow (3.0.0)
80
90
  rake (12.3.3)
81
- reek (6.0.2)
91
+ reek (6.0.4)
82
92
  kwalify (~> 0.7.0)
83
- parser (>= 2.5.0.0, < 2.8, != 2.5.1.1)
93
+ parser (~> 3.0.0)
84
94
  psych (~> 3.1)
85
95
  rainbow (>= 2.0, < 4.0)
86
- regexp_parser (2.0.3)
87
- representable (3.0.4)
96
+ regexp_parser (2.1.1)
97
+ representable (3.1.1)
88
98
  declarative (< 0.1.0)
89
- declarative-option (< 0.2.0)
99
+ trailblazer-option (>= 0.1.1, < 0.2.0)
90
100
  uber (< 0.2.0)
91
101
  retriable (3.1.2)
92
102
  reverse_markdown (2.0.0)
93
103
  nokogiri
94
- rexml (3.2.4)
95
- rubocop (1.7.0)
104
+ rexml (3.2.5)
105
+ rubocop (1.16.0)
96
106
  parallel (~> 1.10)
97
- parser (>= 2.7.1.5)
107
+ parser (>= 3.0.0.0)
98
108
  rainbow (>= 2.2.2, < 4.0)
99
109
  regexp_parser (>= 1.8, < 3.0)
100
110
  rexml
101
- rubocop-ast (>= 1.2.0, < 2.0)
111
+ rubocop-ast (>= 1.7.0, < 2.0)
102
112
  ruby-progressbar (~> 1.7)
103
- unicode-display_width (>= 1.4.0, < 2.0)
104
- rubocop-ast (1.4.0)
105
- parser (>= 2.7.1.5)
113
+ unicode-display_width (>= 1.4.0, < 3.0)
114
+ rubocop-ast (1.7.0)
115
+ parser (>= 3.0.1.1)
106
116
  rubocop-rake (0.5.1)
107
117
  rubocop
108
118
  ruby-progressbar (1.11.0)
109
- ruby2_keywords (0.0.2)
110
- signet (0.14.0)
119
+ ruby2_keywords (0.0.4)
120
+ signet (0.15.0)
111
121
  addressable (~> 2.3)
112
122
  faraday (>= 0.17.3, < 2.0)
113
123
  jwt (>= 1.5, < 3.0)
114
124
  multi_json (~> 1.10)
115
- solargraph (0.40.1)
125
+ solargraph (0.41.1)
116
126
  backport (~> 1.1)
117
127
  benchmark
118
128
  bundler (>= 1.17.2)
@@ -120,16 +130,18 @@ GEM
120
130
  jaro_winkler (~> 1.5)
121
131
  kramdown (~> 2.3)
122
132
  kramdown-parser-gfm (~> 1.1)
123
- parser (~> 2.3)
133
+ parser (~> 3.0)
124
134
  reverse_markdown (>= 1.0.5, < 3)
125
135
  rubocop (>= 0.52)
126
136
  thor (~> 1.0)
127
137
  tilt (~> 2.0)
128
138
  yard (~> 0.9, >= 0.9.24)
129
- thor (1.0.1)
139
+ thor (1.1.0)
130
140
  tilt (2.0.10)
141
+ trailblazer-option (0.1.1)
131
142
  uber (0.1.0)
132
- unicode-display_width (1.7.0)
143
+ unicode-display_width (2.0.0)
144
+ webrick (1.7.0)
133
145
  yard (0.9.26)
134
146
 
135
147
  PLATFORMS
data/bin/console CHANGED
File without changes
data/bin/setup CHANGED
File without changes
data/lib/cns/bigquery2.rb CHANGED
@@ -15,7 +15,7 @@ module Cns
15
15
  # @return [String] comando insert SQL formatado eth2bh
16
16
  def eth2bh_ins
17
17
  "insert #{BD}.eth2bh(balance,effectivebalance,epoch,validatorindex" \
18
- ") VALUES#{apibc.nov[0..1000].map { |obj| eth2bh_1val(obj) }.join(',')}"
18
+ ") VALUES#{apibc.nov[0..1300].map { |obj| eth2bh_1val(obj) }.join(',')}"
19
19
  end
20
20
 
21
21
  # @return [Etherscan] API blockchain ETH
@@ -68,7 +68,7 @@ module Cns
68
68
  # @param [Hash] abc account etherscan
69
69
  # @return [Hash] dados etherscan - address, saldo & transacoes
70
70
  def base_bc(abc)
71
- acc = abc[:account]
71
+ acc = abc[:account].downcase
72
72
  {
73
73
  ax: acc,
74
74
  sl: (abc[:balance].to_d / 10**18).round(10),
@@ -99,7 +99,7 @@ module Cns
99
99
  def filtrar_tx(add, ary)
100
100
  # elimina transferencia from: (lax) to: (add) - esta transferencia aparece em from: (add) to: (lax)
101
101
  # elimina chaves irrelevantes (DL) & adiciona chave indice itx & adiciona identificador da carteira iax
102
- ary.delete_if { |odl| odl[:to] == add && lax.include?(odl[:from]) }
102
+ ary.delete_if { |odl| add.casecmp?(odl[:to]) && lax.include?(odl[:from].downcase) }
103
103
  .map { |omp| omp.delete_if { |key, _| DL.include?(key) }.merge(itx: Integer(omp[:blockNumber]), iax: add) }
104
104
  end
105
105
 
data/lib/cns/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Cns
4
- VERSION = '0.2.1'
4
+ VERSION = '0.2.6'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cns
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hernâni Rodrigues Vaz
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-01-10 00:00:00.000000000 Z
11
+ date: 2021-06-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -168,8 +168,7 @@ description: Arquiva transactions etherscan/greymass/bitcoinde/kraken/paymium/th
168
168
  no bigquery. Pode ajustar dias para reposicionamento temporal.
169
169
  email:
170
170
  - hernanirvaz@gmail.com
171
- executables:
172
- - cns
171
+ executables: []
173
172
  extensions: []
174
173
  extra_rdoc_files: []
175
174
  files:
@@ -186,7 +185,6 @@ files:
186
185
  - bin/console
187
186
  - bin/setup
188
187
  - cns.gemspec
189
- - exe/cns
190
188
  - lib/cns.rb
191
189
  - lib/cns/apibc.rb
192
190
  - lib/cns/apice1.rb
@@ -227,7 +225,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
227
225
  - !ruby/object:Gem::Version
228
226
  version: '0'
229
227
  requirements: []
230
- rubygems_version: 3.1.2
228
+ rubygems_version: 3.1.4
231
229
  signing_key:
232
230
  specification_version: 4
233
231
  summary: Arquiva transactions etherscan/greymass/bitcoinde/kraken/paymium/therock
data/exe/cns DELETED
@@ -1,6 +0,0 @@
1
- #!/usr/bin/env ruby
2
- # frozen_string_literal: true
3
-
4
- require('cns')
5
-
6
- Cns::CLI.start(ARGV)