relaton-itu 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/Gemfile +3 -0
- data/Gemfile.lock +13 -13
- data/lib/relaton_itu/itu_bibliography.rb +3 -3
- data/lib/relaton_itu/scrapper.rb +3 -0
- data/lib/relaton_itu/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c3a28ee1d4e888cee0a517af8cd8789b158af039
|
4
|
+
data.tar.gz: 258f1376b52da45332a7884ac483fdc141e0053c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 70361e0a954f2f5d075a7d3349cae152268a84dee0b17840bf47a2a3693ca897cc56e73406c7d3ab27139961f9f698653ad8dc33d52e27f682be5c2deebb1606
|
7
|
+
data.tar.gz: ca3e769b43e48db0b04ac2aeb74ff1091d6cc590baa61aa7603f10793484bc97917b6944786064bb45ce0a82825cf199cc66179e660b8850d253e83ebd829447
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
relaton-itu (0.2.
|
4
|
+
relaton-itu (0.2.1)
|
5
5
|
relaton-iso-bib (~> 0.2.0)
|
6
6
|
|
7
7
|
GEM
|
@@ -15,9 +15,9 @@ GEM
|
|
15
15
|
safe_yaml (~> 1.0.0)
|
16
16
|
debase (0.2.2)
|
17
17
|
debase-ruby_core_source (>= 0.10.2)
|
18
|
-
debase-ruby_core_source (0.10.
|
18
|
+
debase-ruby_core_source (0.10.5)
|
19
19
|
diff-lcs (1.3)
|
20
|
-
docile (1.3.
|
20
|
+
docile (1.3.2)
|
21
21
|
equivalent-xml (0.6.0)
|
22
22
|
nokogiri (>= 1.4.3)
|
23
23
|
hashdiff (0.4.0)
|
@@ -33,12 +33,12 @@ GEM
|
|
33
33
|
pry-byebug (3.7.0)
|
34
34
|
byebug (~> 11.0)
|
35
35
|
pry (~> 0.10)
|
36
|
-
public_suffix (3.1.
|
36
|
+
public_suffix (3.1.1)
|
37
37
|
rake (10.5.0)
|
38
|
-
relaton-bib (0.2.
|
38
|
+
relaton-bib (0.2.3)
|
39
39
|
addressable
|
40
40
|
nokogiri (~> 1.8.4)
|
41
|
-
relaton-iso-bib (0.2.
|
41
|
+
relaton-iso-bib (0.2.3)
|
42
42
|
isoics (~> 0.1.6)
|
43
43
|
nokogiri (~> 1.8.4)
|
44
44
|
relaton-bib (~> 0.2.0)
|
@@ -47,16 +47,16 @@ GEM
|
|
47
47
|
rspec-core (~> 3.8.0)
|
48
48
|
rspec-expectations (~> 3.8.0)
|
49
49
|
rspec-mocks (~> 3.8.0)
|
50
|
-
rspec-core (3.8.
|
50
|
+
rspec-core (3.8.1)
|
51
51
|
rspec-support (~> 3.8.0)
|
52
|
-
rspec-expectations (3.8.
|
52
|
+
rspec-expectations (3.8.4)
|
53
53
|
diff-lcs (>= 1.2.0, < 2.0)
|
54
54
|
rspec-support (~> 3.8.0)
|
55
|
-
rspec-mocks (3.8.
|
55
|
+
rspec-mocks (3.8.1)
|
56
56
|
diff-lcs (>= 1.2.0, < 2.0)
|
57
57
|
rspec-support (~> 3.8.0)
|
58
|
-
rspec-support (3.8.
|
59
|
-
ruby-debug-ide (0.
|
58
|
+
rspec-support (3.8.2)
|
59
|
+
ruby-debug-ide (0.7.0)
|
60
60
|
rake (>= 0.8.1)
|
61
61
|
ruby_deep_clone (0.8.0)
|
62
62
|
safe_yaml (1.0.5)
|
@@ -66,10 +66,10 @@ GEM
|
|
66
66
|
simplecov-html (~> 0.10.0)
|
67
67
|
simplecov-html (0.10.2)
|
68
68
|
vcr (5.0.0)
|
69
|
-
webmock (3.
|
69
|
+
webmock (3.6.0)
|
70
70
|
addressable (>= 2.3.6)
|
71
71
|
crack (>= 0.3.2)
|
72
|
-
hashdiff
|
72
|
+
hashdiff (>= 0.4.0, < 2.0.0)
|
73
73
|
|
74
74
|
PLATFORMS
|
75
75
|
ruby
|
@@ -18,9 +18,9 @@ module RelatonItu
|
|
18
18
|
# @return [RelatonItu::HitCollection]
|
19
19
|
def search(text, year = nil)
|
20
20
|
HitCollection.new text, year
|
21
|
-
rescue
|
22
|
-
|
23
|
-
|
21
|
+
rescue SocketError, Timeout::Error, Errno::EINVAL, Errno::ECONNRESET, EOFError,
|
22
|
+
Net::HTTPBadResponse, Net::HTTPHeaderSyntaxError, Net::ProtocolError
|
23
|
+
raise RelatonBib::RequestError, "Could not access http://www.itu.int"
|
24
24
|
end
|
25
25
|
|
26
26
|
# @param code [String] the ISO standard Code to look up (e..g "ISO 9000")
|
data/lib/relaton_itu/scrapper.rb
CHANGED
@@ -119,6 +119,9 @@ module RelatonItu
|
|
119
119
|
resp = Net::HTTP.get_response(uri) # .encode("UTF-8")
|
120
120
|
end
|
121
121
|
Nokogiri::HTML(resp.body)
|
122
|
+
rescue SocketError, Timeout::Error, Errno::EINVAL, Errno::ECONNRESET, EOFError,
|
123
|
+
Net::HTTPBadResponse, Net::HTTPHeaderSyntaxError, Net::ProtocolError
|
124
|
+
raise RelatonBib::RequestError, "Could not access #{url}"
|
122
125
|
end
|
123
126
|
# rubocop:enable Metrics/AbcSize, Metrics/MethodLength
|
124
127
|
|
data/lib/relaton_itu/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-itu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-06-
|
11
|
+
date: 2019-06-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -216,7 +216,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
216
216
|
version: '0'
|
217
217
|
requirements: []
|
218
218
|
rubyforge_project:
|
219
|
-
rubygems_version: 2.
|
219
|
+
rubygems_version: 2.6.12
|
220
220
|
signing_key:
|
221
221
|
specification_version: 4
|
222
222
|
summary: 'RelatonItu: retrieve ITU Standards for bibliographic use using the BibliographicItem
|