junkie 0.0.7 → 0.0.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -113,22 +113,30 @@ module Junkie
113
113
  def monitor_progress
114
114
  log.debug("Watchdog timer has been fired")
115
115
  in_fiber {
116
- catch(:break) {
117
- queue_data = get_queue_data
116
+ catch(:break) do
118
117
 
119
- # check for empty queue and disable watchdog if needed
120
- check_for_empty_queue(queue_data)
118
+ begin
119
+ queue_data = get_queue_data
121
120
 
122
- # extract package IDs and map them to current downloads
123
- update_package_ids(queue_data)
121
+ # check for empty queue and disable watchdog if needed
122
+ check_for_empty_queue(queue_data)
124
123
 
125
- check_for_failed_links(queue_data)
124
+ # extract package IDs and map them to current downloads
125
+ update_package_ids(queue_data)
126
126
 
127
- check_for_complete_packages(queue_data)
128
- }
127
+ check_for_failed_links(queue_data)
128
+
129
+ check_for_complete_packages(queue_data)
130
+
131
+ rescue Junkie::InvalidResponse => e
132
+ log.error(
133
+ "Pyload returns InvalidResponse (#{e}), I will ignore this")
134
+ rescue Exception => e
135
+ log.error(
136
+ "an unexpected error is occured (#{e}), I will ignore this")
137
+ end
138
+ end
129
139
  }
130
- rescue Junkie::InvalidResponse => e
131
- log.error("Pyload returns InvalidResponse (#{e}), I will ignore this")
132
140
  end
133
141
 
134
142
 
@@ -1,3 +1,3 @@
1
1
  module Junkie
2
- VERSION = "0.0.7"
2
+ VERSION = "0.0.8"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: junkie
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.7
4
+ version: 0.0.8
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-15 00:00:00.000000000 Z
12
+ date: 2012-12-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: eventmachine