sidekiq 4.2.0 → 4.2.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of sidekiq might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: db0f25c2fe7ea87588364c3eb86e3b929197139c
4
- data.tar.gz: 8fa8c056e6c5fad50ce5d49838515aca61573458
3
+ metadata.gz: b58398d83dbfb9cc56c80dfe0745ed41205a6587
4
+ data.tar.gz: 4720f2338df1fbe4922f7e417fa4b50f61f84827
5
5
  SHA512:
6
- metadata.gz: 4a801ac5f3d70ca6e1856cb7369f557d5bb8d1c579e775f6a4f5ed97d534af2d289f884979de978f3a7cab2d1261fabeef6b7fc9e73b1684c7b1daabbd25e0e7
7
- data.tar.gz: 37c617e0ea241fe8cea7c85e6479e2259e06f1b5bfb06ce811b2529d73adc8a09a67655dbdcaff028ba4cd3226169a79f636f813f7848d7fe8eaa084ea9d5739
6
+ metadata.gz: 77d880117249a7ee38f7c40fd3b3b1ade91091b2da7182fe4ffc9c2d9494825d5b1e70ec6cf6b26bb0b74d172f0dee5a7d26ffe8a04d80c29a70d5daf8274bf7
7
+ data.tar.gz: bf99316c61de44f0d8d1332d6841b6b60e00fa7639d6a2fa04a4f273eb22c0ec8c3aa7c38a5068322a2d6a023d7918f39e7392d98d3926776192868fb5c44a14
data/Changes.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Sidekiq Changes
2
2
 
3
+ 4.2.1
4
+ -----------
5
+
6
+ - Ensure browser does not cache JSON/AJAX responses. [#3136]
7
+ - Support old Sinatra syntax for setting config [#3139]
8
+
3
9
  4.2.0
4
10
  -----------
5
11
 
data/README.md CHANGED
@@ -84,8 +84,8 @@ Useful resources:
84
84
 
85
85
  **No support via Twitter, 140 characters is not enough.**
86
86
 
87
- Every Friday morning 9am Pacific is Sidekiq happy hour: I video chat and answer questions.
88
- See the [Sidekiq support page](http://sidekiq.org/support).
87
+ Every Friday morning is Sidekiq happy hour: I video chat and answer questions.
88
+ See the [Sidekiq support page](http://sidekiq.org/support) for details.
89
89
 
90
90
  Thanks
91
91
  -----------------
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Sidekiq
3
- VERSION = "4.2.0"
3
+ VERSION = "4.2.1"
4
4
  end
@@ -63,6 +63,11 @@ module Sidekiq
63
63
  @views ||= VIEWS
64
64
  end
65
65
 
66
+ # Helper for the Sinatra syntax: Sidekiq::Web.set(:session_secret, Rails.application.secrets...)
67
+ def set(attribute, value)
68
+ send(:"#{attribute}=", value)
69
+ end
70
+
66
71
  attr_accessor :app_url, :session_secret, :redis_pool
67
72
  attr_writer :locales, :views
68
73
  end
@@ -2,13 +2,9 @@
2
2
 
3
3
  module Sidekiq
4
4
  class WebAction
5
- RACK_SESSION = 'rack.session'.freeze
6
-
7
- LOCATION = "Location".freeze
8
-
9
- CONTENT_TYPE = "Content-Type".freeze
10
- TEXT_HTML = { CONTENT_TYPE => "text/html".freeze, "Cache-Control" => "no-cache" }
11
- APPLICATION_JSON = { CONTENT_TYPE => "application/json".freeze }
5
+ RACK_SESSION = 'rack.session'
6
+ TEXT_HTML = { "Content-Type" => "text/html", "Cache-Control" => "no-cache" }
7
+ APPLICATION_JSON = { "Content-Type" => "application/json", "Cache-Control" => "no-cache" }
12
8
 
13
9
  attr_accessor :env, :block, :type
14
10
 
@@ -25,7 +21,7 @@ module Sidekiq
25
21
  end
26
22
 
27
23
  def redirect(location)
28
- throw :halt, [302, { LOCATION => "#{request.base_url}#{location}" }, []]
24
+ throw :halt, [302, { "Location" => "#{request.base_url}#{location}" }, []]
29
25
  end
30
26
 
31
27
  def params
@@ -28,6 +28,11 @@ class TestWeb < Sidekiq::Test
28
28
  end
29
29
  end
30
30
 
31
+ it 'can configure via set() syntax' do
32
+ app.set(:session_secret, "foo")
33
+ assert_equal "foo", app.session_secret
34
+ end
35
+
31
36
  it 'can show text with any locales' do
32
37
  rackenv = {'HTTP_ACCEPT_LANGUAGE' => 'ru,en'}
33
38
  get '/', {}, rackenv
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.0
4
+ version: 4.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Perham
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-13 00:00:00.000000000 Z
11
+ date: 2016-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: redis