reddit_bot 1.9.0 → 1.10.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 99ebebd30c2e4bfa221cc6b78c6521f4eb2e5c7b
4
- data.tar.gz: 79b8d91f910d5ca649f8350f1009bb6c21afd702
3
+ metadata.gz: 6a4b6056d152bae03ffd563ae1a4fd1074871cd9
4
+ data.tar.gz: ae3eeee686686d80659b91d702f752617333c065
5
5
  SHA512:
6
- metadata.gz: 9049548db4c55006a9fd9dd7fef394cb3b973ea3df7047a25528dcd2495e230acaa8217fd17ffa8128e9f23784bd292875d6e01015c785d465c3acc7c51db0b9
7
- data.tar.gz: 6e9849c6d4d3c7ed2eacc8b404f256764e0756e773d567ab7004d7f0a041bbdb5b722106d4fbba281b1ef0f8b6898d551b7742b19a232b942058523e8235a669
6
+ metadata.gz: 732462c5e167fdab3520dd669687e0871a67ff781613befe9e4ea5122e2b383f44a2fa8ce9fdbb14ea208c26e407b901b070851a033019ac285ba91a32504c7c
7
+ data.tar.gz: 865ef62f2c73a4de9fddc5ea4af0ba8ab9c03856bb1e6d093e5f7ca8767bf67dbae37b3c78fae3eeead39b7fd1824199fba8e33ae8eaf8aec0211a7f4e80af59
data/lib/reddit_bot.rb CHANGED
@@ -138,8 +138,11 @@ module RedditBot
138
138
  result = cache.call(args){ json *args }
139
139
  fail if result.keys != %w{ kind data }
140
140
  fail if result["kind"] != "Listing"
141
- fail result["data"].keys.inspect unless result["data"].keys == %w{ after dist modhash whitelist_status children before } ||
142
- result["data"].keys == %w{ modhash dist children after before }
141
+ fail result["data"].keys.inspect unless [
142
+ %w{ after dist modhash whitelist_status children before },
143
+ %w{ modhash dist children after before },
144
+ %w{ after dist modhash geo_filter children before },
145
+ ].include? result["data"].keys
143
146
  @@skip_erroneous_descending_ids[ result["data"]["children"].map do |post|
144
147
  fail "unknown type post['kind']: #{post["kind"]}" unless post["kind"] == "t3"
145
148
  post["data"].dup.tap do |data|
@@ -282,6 +285,7 @@ module RedditBot
282
285
 
283
286
  require "cgi"
284
287
  def self.tweet2titleNtext tweet
288
+ pp tweet if ENV["TEST"]
285
289
  text = ""
286
290
  contains_media = false
287
291
  up = ->s{ s.split.map{ |w| "^#{w}" }.join " " }
data/reddit_bot.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "reddit_bot"
3
- spec.version = "1.9.0"
3
+ spec.version = "1.10.0"
4
4
  spec.summary = "Simple library for Reddit bots"
5
5
 
6
6
  spec.author = "Victor Maslov aka Nakilon"
@@ -9,7 +9,7 @@ Gem::Specification.new do |spec|
9
9
  spec.metadata = {"source_code_uri" => "https://github.com/Nakilon/reddit_bot"}
10
10
 
11
11
  spec.add_dependency "json_pure"
12
- spec.add_dependency "nethttputils", "~>0.4.1.0"
12
+ spec.add_dependency "nethttputils", "~>0.4.2.0"
13
13
  # spec.add_development_dependency "bundler", "~> 1.11"
14
14
  # spec.add_development_dependency "rake", "~> 10.0"
15
15
  # spec.add_development_dependency "rspec", "~> 3.0"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: reddit_bot
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.0
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Victor Maslov aka Nakilon
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-02-16 00:00:00.000000000 Z
11
+ date: 2021-10-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json_pure
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 0.4.1.0
33
+ version: 0.4.2.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 0.4.1.0
40
+ version: 0.4.2.0
41
41
  description:
42
42
  email: nakilon@gmail.com
43
43
  executables: []