goodreads 0.7.0 → 0.8.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 276c50ce4b9f6de62271e47d8aec25e242e84ef11530feb12acf7d4a4de222ef
4
- data.tar.gz: 03a4efbece5151e893054f66395246ad69703c0dd8d1552e123ff543f794dd55
3
+ metadata.gz: 6ea0e771d6f0bb4fe73d87bdc54b96f97c26e58e2dca54c0d956f73263acf557
4
+ data.tar.gz: 78e582d52e5ddfee249448c3f5bef36e8f56e165c5d241e3f8cb4c9633d6730a
5
5
  SHA512:
6
- metadata.gz: e965de073780bc5953ac3e119e3f0b6e8366670bd49900270fcaafa37c448e8fc154806d0a8cead6cb1c968079c5b09d5a7516df3eb7f29ec1282770ee3f9b9b
7
- data.tar.gz: 5db33e6618b1f16366af3720287a9a49530b63cc639a846c2dad3a45ae610b333ceddd5da076b8cf8c58c6b5c8fe92db7b934138b6ad71ed2c83e67413bdbdf3
6
+ metadata.gz: 70521658f5c0df28b749559f336ed4c6e418257914fa7b3e4572e88166a1347eca0197422ba8c48bbefc4e9c55ca57524aeee83ae6f2b94f41b1846e90d55f70
7
+ data.tar.gz: d309c6a3874443910a06b7d156a87f29764be70ac6cb79bad8692b0b1436958b31730f3673bf473f4be569b4dda8a321459d53a30e4e0fad098058f9e5734925
@@ -1,11 +1,10 @@
1
1
  sudo: false
2
2
 
3
3
  rvm:
4
- - 2.1
5
- - 2.2
6
4
  - 2.3
7
5
  - 2.4
8
6
  - 2.5
7
+ - 2.6
9
8
 
10
9
  script:
11
10
  - bundle exec rake test
data/README.md CHANGED
@@ -170,7 +170,6 @@ group_list.total # => total number of groups
170
170
  group_list.group.count # => number of groups returned in the request
171
171
 
172
172
  # Loop through the list to get details for each of the groups.
173
-
174
173
  group_list.group.each do |g|
175
174
  g.id # => group id
176
175
  g.access # => access settings (private, public)
@@ -184,6 +183,14 @@ end
184
183
  The `sort` parameter is optional, and defaults to `my_activity`.
185
184
  For other sorting options, [see here](http://www.goodreads.com/api#group.list).
186
185
 
186
+ ### Pagination
187
+
188
+ To retrieve results for a particular page use the `page` param when making calls:
189
+
190
+ ```ruby
191
+ books = client.search_books("Term", page: 2)
192
+ ```
193
+
187
194
  ### OAuth
188
195
 
189
196
  For API calls requiring permission, such as write operations or browsing friends,
@@ -4,4 +4,6 @@ module Goodreads
4
4
  class Forbidden < Error; end
5
5
  class Unauthorized < Error; end
6
6
  class NotFound < Error; end
7
+ class ServerError < Error; end
8
+ class UnknownError < Error; end
7
9
  end
@@ -46,6 +46,10 @@ module Goodreads
46
46
  fail(Goodreads::Forbidden)
47
47
  when 404
48
48
  fail(Goodreads::NotFound)
49
+ when 500..599
50
+ fail(Goodreads::ServerError.new(response.code))
51
+ else
52
+ fail(Goodreads::UnknownError.new(response.code))
49
53
  end
50
54
  end
51
55
 
@@ -1,3 +1,3 @@
1
1
  module Goodreads
2
- VERSION = "0.7.0"
2
+ VERSION = "0.8.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: goodreads
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dan Sosedoff
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-12 00:00:00.000000000 Z
11
+ date: 2020-11-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: webmock
@@ -215,7 +215,7 @@ homepage: http://github.com/sosedoff/goodreads
215
215
  licenses:
216
216
  - MIT
217
217
  metadata: {}
218
- post_install_message:
218
+ post_install_message:
219
219
  rdoc_options: []
220
220
  require_paths:
221
221
  - lib
@@ -230,9 +230,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
230
230
  - !ruby/object:Gem::Version
231
231
  version: '0'
232
232
  requirements: []
233
- rubyforge_project:
234
- rubygems_version: 2.7.9
235
- signing_key:
233
+ rubygems_version: 3.0.6
234
+ signing_key:
236
235
  specification_version: 4
237
236
  summary: Goodreads API wrapper
238
237
  test_files: