rbbt-util 5.13.12 → 5.13.13
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rbbt/util/log/progress/report.rb +10 -2
- data/lib/rbbt/workflow/accessor.rb +3 -1
- data/lib/rbbt/workflow/step.rb +5 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 277f1c14f20cd7554ee5a003b6c85236421bae33
|
4
|
+
data.tar.gz: 3dd0c58cb609fc0e2f23f44c0346c3b11c0dc33b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a2ca47df42c824b5dfb3747d0369bf8de58299838c6eaef15b6f0c24e8285368ce5029a56a1c60863f4c5b21ca7fafb7f6fe4235bf54d9ad58306f930621f266
|
7
|
+
data.tar.gz: aa7b5ce64c52aebf03cd1c095eea0a6e8d08d860206195a40e06afa3e1d529d645a7e29c37e2f94b056f654f4a215172f66b983218187dc38b310774385d64c0
|
@@ -20,7 +20,11 @@ module Log
|
|
20
20
|
attr_accessor :history, :mean_max
|
21
21
|
def thr
|
22
22
|
count = @ticks - @last_count
|
23
|
-
|
23
|
+
if @last_time.nil?
|
24
|
+
seconds = 0.001
|
25
|
+
else
|
26
|
+
seconds = Time.now - @last_time
|
27
|
+
end
|
24
28
|
thr = count / seconds
|
25
29
|
end
|
26
30
|
|
@@ -99,7 +103,11 @@ module Log
|
|
99
103
|
|
100
104
|
def done(io = STDERR)
|
101
105
|
done_msg = Log.color(:magenta, desc) << " " << Log.color(:green, "done")
|
102
|
-
|
106
|
+
if @start
|
107
|
+
ellapsed = (Time.now - @start).to_i
|
108
|
+
else
|
109
|
+
ellapsed = 0
|
110
|
+
end
|
103
111
|
ellapsed = [ellapsed/3600, ellapsed/60 % 60, ellapsed % 60].map{|t| "%02i" % t }.join(':')
|
104
112
|
done_msg << " " << Log.color(:blue, (@ticks).to_s) << " in " << Log.color(:green, ellapsed)
|
105
113
|
@last_count = 0
|
@@ -208,9 +208,11 @@ class Step
|
|
208
208
|
|
209
209
|
def exception(ex, msg = nil)
|
210
210
|
self._abort
|
211
|
+
ex_class = ex.class.to_s
|
211
212
|
set_info :backtrace, ex.backtrace
|
213
|
+
set_info :exception, {:class => ex_class, :message => ex.message, :backtrace => ex.backtrace}
|
212
214
|
if msg.nil?
|
213
|
-
log :error, "
|
215
|
+
log :error, "#{ex_class} -- #{ex.message}"
|
214
216
|
else
|
215
217
|
log :error, "#{msg} -- #{ex.message}"
|
216
218
|
end
|
data/lib/rbbt/workflow/step.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rbbt-util
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.13.
|
4
|
+
version: 5.13.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Miguel Vazquez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
11
|
+
date: 2014-05-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|