download_tv 2.4.5 → 2.4.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/download_tv.gemspec +0 -2
- data/lib/download_tv/grabbers/torrentapi.rb +7 -2
- data/lib/download_tv/torrent.rb +2 -1
- data/lib/download_tv/version.rb +1 -1
- data/test/downloader_test.rb +0 -7
- data/test/torrent_test.rb +2 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e377266cc2744dc9f250731064ea8c72bc41a1b7395e1d7f08d04df6e659fb6c
|
4
|
+
data.tar.gz: 9761596d5643b869e501c6f6df18343944050c10f946cefd09c604ff88a301ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2cb1468ca23f32f8a172c7d0142a2177251ac3def0c3f66c64bd63295c1b9ac431e075c897004577332a13219e74c76d16429083b0c4986fe0f4651b5797af8b
|
7
|
+
data.tar.gz: 8525d7675966c1924cbb4e48740e59d2834c9c082668f87e00e1f813aea81ac7cdbdd6d8d8b63840b73e202beb8539425a0be2d7c88d95eeaf274948d397f05e
|
data/download_tv.gemspec
CHANGED
@@ -21,7 +21,6 @@ Gem::Specification.new do |s|
|
|
21
21
|
s.require_paths = ['lib']
|
22
22
|
|
23
23
|
s.executables = ['tv']
|
24
|
-
s.default_executable = 'tv'
|
25
24
|
|
26
25
|
s.add_development_dependency 'bundler', '~> 1.15'
|
27
26
|
s.add_development_dependency 'rake', '~> 10.0'
|
@@ -30,6 +29,5 @@ Gem::Specification.new do |s|
|
|
30
29
|
s.add_dependency('json')
|
31
30
|
s.add_dependency('mechanize')
|
32
31
|
|
33
|
-
s.has_rdoc = false
|
34
32
|
s.license = 'MIT'
|
35
33
|
end
|
@@ -17,8 +17,13 @@ module DownloadTV
|
|
17
17
|
@agent.read_timeout = 2
|
18
18
|
renew_token
|
19
19
|
true
|
20
|
-
rescue Mechanize::ResponseCodeError, Net::HTTP::Persistent::Error
|
21
|
-
|
20
|
+
rescue Mechanize::ResponseCodeError, Net::HTTP::Persistent::Error => e
|
21
|
+
if e.response_code == '429'
|
22
|
+
sleep(@wait)
|
23
|
+
retry
|
24
|
+
else
|
25
|
+
false
|
26
|
+
end
|
22
27
|
end
|
23
28
|
|
24
29
|
##
|
data/lib/download_tv/torrent.rb
CHANGED
data/lib/download_tv/version.rb
CHANGED
data/test/downloader_test.rb
CHANGED
@@ -78,13 +78,6 @@ describe DownloadTV::Downloader do
|
|
78
78
|
dl.filter_shows(links).must_equal res
|
79
79
|
end
|
80
80
|
|
81
|
-
it 'removes names with WEB in them' do
|
82
|
-
dl = DownloadTV::Downloader.new(path: config_path)
|
83
|
-
links = [['Link 1 WEBRIP', ''], ['Link 2 rip', ''], ['Link.720p.rip', '']]
|
84
|
-
res = [['Link 2 rip', '']]
|
85
|
-
dl.filter_shows(links).must_equal res
|
86
|
-
end
|
87
|
-
|
88
81
|
it 'removes names without PROPER or REPACK in them' do
|
89
82
|
dl = DownloadTV::Downloader.new(path: config_path)
|
90
83
|
links = [['Link 1', ''], ['Link 2 2160p', ''], ['Link 3', ''], ['Link 4 PROPER', ''], ['Link REPACK 5', '']]
|
data/test/torrent_test.rb
CHANGED
@@ -24,7 +24,8 @@ describe DownloadTV::Torrent do
|
|
24
24
|
describe 'when giving it a default grabber' do
|
25
25
|
it 'has a default order' do
|
26
26
|
t = DownloadTV::Torrent.new(nil)
|
27
|
-
t.
|
27
|
+
expected = t.grabbers.map { |i| "DownloadTV::#{i}"}
|
28
|
+
t.g_instances.map { |i| i.class.name}.must_equal expected
|
28
29
|
end
|
29
30
|
|
30
31
|
%w[Eztv KAT ThePirateBay TorrentAPI].each do |g|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: download_tv
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- guille
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-07-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -134,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
134
134
|
version: '0'
|
135
135
|
requirements: []
|
136
136
|
rubyforge_project:
|
137
|
-
rubygems_version: 2.7.
|
137
|
+
rubygems_version: 2.7.7
|
138
138
|
signing_key:
|
139
139
|
specification_version: 4
|
140
140
|
summary: DownloadTV is a tool that allows the user to find magnet links for tv show
|