miga-base 1.3.20.8 → 1.3.20.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/miga/cli/action/doctor/distances.rb +10 -6
- data/lib/miga/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1fc1b49c630d4e619c3394850d15b692cab359f617970ce6f3235e8f6c373d6c
|
4
|
+
data.tar.gz: 2c2c6bb6ee77b873993a6ecea24047ca854acd31e88a43ee9588c350df0a719b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 86a62582ae62601a5c3e3935b5bae8046e97a19b53624827d20a8728066ec68360664042a213ee094346e7dba63d8765a044cbc413bcafc3bd8f841579371c1f
|
7
|
+
data.tar.gz: 7ad47d39abd7c257c23b8bdf825135a51dd8e9fa2c96cc14881a16e5a8e03264d9541381796616462c8e6bf3b4a85cfd5ff0528539447e2f3e487aceafa6bb48
|
@@ -141,18 +141,22 @@ module MiGA::Cli::Action::Doctor::Distances
|
|
141
141
|
end
|
142
142
|
MiGA::Parallel.distribute(lower_triangle, cli[:threads]) do |cell, k, thr|
|
143
143
|
cli.advance('Writing:', k, lower_triangle.size, false) if thr == 0
|
144
|
+
done_f = File.join(tmp, "#{cell[0]}-#{cell[1]}.txt")
|
145
|
+
next if File.exist?(done_f)
|
146
|
+
|
144
147
|
fixed_ds = merge_bidir_tmp_pair(tmp, cell[0], cell[1])
|
145
|
-
File.open(
|
146
|
-
|
147
|
-
end
|
148
|
+
File.open("#{done_f}.tmp", 'w') { |fh| fixed_ds.each { |ds| fh.puts ds } }
|
149
|
+
File.rename("#{done_f}.tmp", done_f)
|
148
150
|
end
|
149
151
|
cli.advance('Writing:', lower_triangle.size, lower_triangle.size, false)
|
150
152
|
cli.say
|
151
153
|
lower_triangle.map do |cell|
|
152
154
|
Set.new.tap do |y|
|
153
|
-
File.
|
154
|
-
|
155
|
-
|
155
|
+
file = File.join(tmp, "#{cell[0]}-#{cell[1]}.txt")
|
156
|
+
raise MiGA::Error.new(
|
157
|
+
"Expected file missing, probably due to a thread failure: #{file}"
|
158
|
+
) unless File.exist?(file)
|
159
|
+
File.open(file, 'r') { |fh| fh.each { |ln| y << ln.chomp } }
|
156
160
|
end
|
157
161
|
end.inject(Set.new, :+)
|
158
162
|
end
|
data/lib/miga/version.rb
CHANGED
@@ -12,7 +12,7 @@ module MiGA
|
|
12
12
|
# - String indicating release status:
|
13
13
|
# - rc* release candidate, not released as gem
|
14
14
|
# - [0-9]+ stable release, released as gem
|
15
|
-
VERSION = [1.3, 20,
|
15
|
+
VERSION = [1.3, 20, 9].freeze
|
16
16
|
|
17
17
|
##
|
18
18
|
# Nickname for the current major.minor version.
|