dh_easy-qa 0.0.33 → 0.0.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/dh_easy/qa/validate_internal.rb +16 -5
- data/lib/dh_easy/qa/version.rb +1 -1
- metadata +6 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8972a854f369585a4f1bc458ded75f5e4ca04d96663cd8a1b13addfbe767dbf2
|
4
|
+
data.tar.gz: 327cce5d1fed72fbb0141498b6712d165cd180ecd31c0c0ed6aa86447243c051
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a58f091f6592d67a1390a8750be93a8a5fd06cab3235005c5ada0bddc295363afe7469106080866a55e0c15833a4fcde6c99afc89d386f780a8d90cb391adbf6
|
7
|
+
data.tar.gz: 7d70c37a9103aed8736823ffaf73facb1d493243fa80c974c0a71fb13e7596e15e937fd7d92faa2413468fbf2afea2bde07bc631992bd0f16f387dc043367fa8
|
@@ -68,7 +68,7 @@ module DhEasy
|
|
68
68
|
end
|
69
69
|
|
70
70
|
def status_ok?
|
71
|
-
!
|
71
|
+
!old_collection_response.parsed_response.nil? && old_collection_response.code == 200
|
72
72
|
end
|
73
73
|
|
74
74
|
def validate_collections
|
@@ -83,19 +83,29 @@ module DhEasy
|
|
83
83
|
end
|
84
84
|
|
85
85
|
def output_response
|
86
|
-
if
|
86
|
+
if old_collection_response.parsed_response.nil?
|
87
87
|
puts "collection response is null"
|
88
88
|
else
|
89
|
-
puts
|
89
|
+
puts old_collection_response.parsed_response['message']
|
90
90
|
end
|
91
91
|
end
|
92
92
|
|
93
93
|
def collection_counts
|
94
|
-
@collection_counts ||= collection_response
|
94
|
+
@collection_counts ||= collection_response
|
95
95
|
end
|
96
96
|
|
97
97
|
def collection_response
|
98
|
-
|
98
|
+
json = JSON.parse(Datahen::Client::ScraperJobOutput.new.collections(scraper_name).body)
|
99
|
+
if json['error'] == ""
|
100
|
+
@collection_response || json["data"]
|
101
|
+
else
|
102
|
+
puts "There was an error: #{JSON.pretty_generate(json['error'])}"
|
103
|
+
@collection_response
|
104
|
+
end
|
105
|
+
end
|
106
|
+
|
107
|
+
def old_collection_response
|
108
|
+
@old_collection_response || Datahen::Client::ScraperJobOutput.new.collections(scraper_name)
|
99
109
|
end
|
100
110
|
end
|
101
111
|
|
@@ -148,6 +158,7 @@ module DhEasy
|
|
148
158
|
data = []
|
149
159
|
page = 1
|
150
160
|
while data.count < total_records
|
161
|
+
# if there is an issue maybe due to this method response due to new stream data response Datahen::Client::JobOutput.new(per_page:500, page: page).all
|
151
162
|
records = Datahen::Client::JobOutput.new(per_page:500, page: page).all(most_recent_finished_job['id'], collection_name).parsed_response
|
152
163
|
sleep 1
|
153
164
|
if records
|
data/lib/dh_easy/qa/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dh_easy-qa
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.34
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Lynam
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dh_easy-config
|
@@ -120,7 +120,7 @@ licenses:
|
|
120
120
|
metadata:
|
121
121
|
homepage_uri: https://datahen.com
|
122
122
|
source_code_uri: https://github.com/DataHenOfficial/dh_easy-qa
|
123
|
-
post_install_message:
|
123
|
+
post_install_message:
|
124
124
|
rdoc_options: []
|
125
125
|
require_paths:
|
126
126
|
- lib
|
@@ -135,9 +135,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
135
135
|
- !ruby/object:Gem::Version
|
136
136
|
version: '0'
|
137
137
|
requirements: []
|
138
|
-
|
139
|
-
|
140
|
-
signing_key:
|
138
|
+
rubygems_version: 3.2.15
|
139
|
+
signing_key:
|
141
140
|
specification_version: 4
|
142
141
|
summary: DataHen Easy Quality Assurance gem
|
143
142
|
test_files: []
|