zold 0.14.29 → 0.14.30

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: 9b4acd567c5e890ca57ca7503ef5620cb7011c92
4
- data.tar.gz: '08020f9c49dcd23340fe4f614190d3d24be30201'
3
+ metadata.gz: 6cc2c9a06ec680bec280cb382f348e26218bb5eb
4
+ data.tar.gz: ea589142c06d8bfa303c92ac2c4d388d507aeb8f
5
5
  SHA512:
6
- metadata.gz: b31303f911f6a4f90b9e5a646e719f0df55163e3f3a4923a7b4953fc9f89fe436d6ed0f846a3115e1852e3308ffe4751a86da717ea0c7aaec13ea3ddf99d16e2
7
- data.tar.gz: a33a1e676dfa1557baafb3f886c38de513ba7c98481d806313a96b5780c723bea580321768e3d1efc502138142ac785394effdaedc56de6e9b7948eed9007254
6
+ metadata.gz: 9c80a2d92a54afe3fb54ade3df2026c8371d3c419b03cc319d60a096e19cbf2070ec633d578a3210a4c37d4858ff286dc6a65bd9cb257a082f6160e882fa8fa5
7
+ data.tar.gz: 678171b14e9da38d467d09ebf5a4a9db30520b467dcba16efb06b75ccc4868b44569e8d15ae280761ef724abfd34c84824dde56734bace91874b080098775375
@@ -145,9 +145,9 @@ module Zold
145
145
  @log.info(pid)
146
146
  return
147
147
  end
148
- trace = Trace.new(@log, opts['trace-length'])
149
- Front.set(:log, trace)
150
- Front.set(:trace, trace)
148
+ @log = Trace.new(@log, opts['trace-length'])
149
+ Front.set(:log, @log)
150
+ Front.set(:trace, @log)
151
151
  Front.set(:version, opts['expose-version'])
152
152
  Front.set(:protocol, Zold::PROTOCOL)
153
153
  Front.set(:logging, @log.debug?)
@@ -174,8 +174,8 @@ module Zold
174
174
  if opts['standalone']
175
175
  @remotes = Zold::Remotes::Empty.new(file: '/tmp/standalone')
176
176
  @log.debug('Running in standalone mode! (will never talk to other remotes)')
177
- else
178
- Zold::Remote.new(remotes: @remotes).run(['remote', 'remove', host, port.to_s, '--force'])
177
+ elsif @remotes.exists?(host, port)
178
+ Zold::Remote.new(remotes: @remotes).run(['remote', 'remove', host, port.to_s])
179
179
  @log.info("Removed current node (#{address}) from list of remotes")
180
180
  end
181
181
  Front.set(:ignore_score_weakness, opts['ignore-score-weakness'])
@@ -68,7 +68,7 @@ module Zold
68
68
  raise "##{Process.pid}/#{Thread.current.name} can't get exclusive access to the wallet #{id}/e \
69
69
  because of the lock at #{lock.path}: #{File.read(lock)}"
70
70
  end
71
- if (cycles % 20).zero?
71
+ if (cycles % 20).zero? && delay > 10
72
72
  @log.info("##{Process.pid}/#{Thread.current.name} still waiting for \
73
73
  exclusive access to #{id}/e, #{delay.round}s already")
74
74
  end
@@ -64,7 +64,7 @@ module Zold
64
64
  raise "##{Process.pid}/#{Thread.current.name} can't get exclusive access to the wallet #{id} \
65
65
  because of the lock at #{lock.path}: #{File.read(lock)}"
66
66
  end
67
- if (cycles % 20).zero?
67
+ if (cycles % 20).zero? && delay > 10
68
68
  @log.info("##{Process.pid}/#{Thread.current.name} still waiting for \
69
69
  exclusive access to #{id}, #{delay.round}s already: #{File.read(lock)}")
70
70
  end
data/lib/zold/version.rb CHANGED
@@ -25,6 +25,6 @@
25
25
  # Copyright:: Copyright (c) 2018 Yegor Bugayenko
26
26
  # License:: MIT
27
27
  module Zold
28
- VERSION = '0.14.29'
28
+ VERSION = '0.14.30'
29
29
  PROTOCOL = 2
30
30
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zold
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.14.29
4
+ version: 0.14.30
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko