rails 4.2.0.rc2 → 4.2.0.rc3

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: 17ec59b4b783e8bbeebcf632264e952d79ac5fad
4
- data.tar.gz: dc3a4b614e6f3fc46b3d591841413c4f3f6dfe19
3
+ metadata.gz: ea9e895f8c4ef510761607e57925bb76d1d03cea
4
+ data.tar.gz: 025cbb96cf14a5279bdd53f0087f56f14f7f99fa
5
5
  SHA512:
6
- metadata.gz: 670eec25cd6c65b40369c00481957d9a1dadba76399872b785e80617009f04a2ad1ff4ef2bb536dbd09df95321db7a350f3b7a5fb71d3a8a9f1feada8ee62c22
7
- data.tar.gz: 75e6da2602e8aa47e830cade8c85ac72c1874e40eb5dd4b45cbe91fe3e8c69047483d4c47939a7cbee6f4e3ab297ac703d5ded150044435b8a5f382b49d11c88
6
+ metadata.gz: 8c88af20de34bf3d26a06f6497a15e671ca60a8fa7fbb5a3f1eb90e0dae1f5b584a514e64b5fe3907cf340f500f50faff2110fd2784b3e6ef16d2915907e0eca
7
+ data.tar.gz: 9644b1cd5497489d0e3382c9bd77cc0a82475c0dcfc42a312be10d4e4d8ec900799f2396bf2ade1d1362b576e689b3932fa7f63568c8e2189616ae70af94a97d
@@ -155,7 +155,7 @@ end
155
155
  # environment
156
156
  ```
157
157
 
158
- The default queue name prefix delimiter is '_'. This can be changed by setting
158
+ The default queue name prefix delimiter is '\_'. This can be changed by setting
159
159
  `config.active_job.queue_name_delimiter` in `application.rb`:
160
160
 
161
161
  ```ruby
@@ -452,6 +452,8 @@ number of digits after the decimal point.
452
452
  are using a dynamic value (such as a date), the default will only be calculated
453
453
  the first time (i.e. on the date the migration is applied).
454
454
  * `index` Adds an index for the column.
455
+ * `required` Adds `required: true` for `belongs_to` associations and
456
+ `null: false` to the column in the migration.
455
457
 
456
458
  Some adapters may support additional options; see the adapter specific API docs
457
459
  for further information.
@@ -231,7 +231,9 @@ images, JavaScript files or stylesheets.
231
231
  scope of the application or those libraries which are shared across applications.
232
232
 
233
233
  * `vendor/assets` is for assets that are owned by outside entities, such as
234
- code for JavaScript plugins and CSS frameworks.
234
+ code for JavaScript plugins and CSS frameworks. Keep in mind that third party
235
+ code with references to other files also processed by the asset Pipeline (images,
236
+ stylesheets, etc.), will need to be rewritten to use helpers like `asset_path`.
235
237
 
236
238
  WARNING: If you are upgrading from Rails 3, please take into account that assets
237
239
  under `lib/assets` or `vendor/assets` are available for inclusion via the
@@ -207,12 +207,47 @@ gem 'rails-deprecated_sanitizer'
207
207
  ```
208
208
 
209
209
  ### Rails DOM Testing
210
+
210
211
  The [`TagAssertions` module](http://api.rubyonrails.org/classes/ActionDispatch/Assertions/TagAssertions.html) (containing methods such as `assert_tag`), [has been deprecated](https://github.com/rails/rails/blob/6061472b8c310158a2a2e8e9a6b81a1aef6b60fe/actionpack/lib/action_dispatch/testing/assertions/dom.rb) in favor of the `assert_select` methods from the `SelectorAssertions` module, which has been extracted into the [rails-dom-testing gem](https://github.com/rails/rails-dom-testing).
211
212
 
212
213
 
213
214
  ### Masked Authenticity Tokens
215
+
214
216
  In order to mitigate SSL attacks, `form_authenticity_token` is now masked so that it varies with each request. Thus, tokens are validated by unmasking and then decrypting. As a result, any strategies for verifying requests from non-rails forms that relied on a static session CSRF token have to take this into account.
215
217
 
218
+ ### Action Mailer
219
+
220
+ Previously, calling a mailer method on a mailer class will result in the
221
+ corresponding instance method being executed directly. With the introduction of
222
+ Active Job and `#deliver_later`, this is no longer true. In Rails 4.2, the
223
+ invocation of the instance methods are deferred until either `deliver_now` or
224
+ `deliver_later` is called. For example:
225
+
226
+ ```ruby
227
+ class Notifier < ActionMailer::Base
228
+ def notify(user, ...)
229
+ puts "Called"
230
+ mail(to: user.email, ...)
231
+ end
232
+ end
233
+
234
+ mail = Notifier.notify(user, ...) # Notifier#welcome is not yet called at this point
235
+ mail = mail.deliver_now # Prints "Called"
236
+ ```
237
+
238
+ This should not result in any noticible differnces for most applications.
239
+ However, if you need some non-mailer methods to be exectuted synchronously, and
240
+ you were previously relying on the synchronous proxying behavior, you should
241
+ define them as class methods on the mailer class directly:
242
+
243
+ ```ruby
244
+ class Notifier < ActionMailer::Base
245
+ def self.broadcast_notifications(users, ...)
246
+ users.each { |user| Notifier.notify(user, ...) }
247
+ end
248
+ end
249
+ ```
250
+
216
251
  Upgrading from Rails 4.0 to Rails 4.1
217
252
  -------------------------------------
218
253
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.0.rc2
4
+ version: 4.2.0.rc3
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-05 00:00:00.000000000 Z
11
+ date: 2014-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -16,144 +16,144 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 4.2.0.rc2
19
+ version: 4.2.0.rc3
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 4.2.0.rc2
26
+ version: 4.2.0.rc3
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: actionpack
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 4.2.0.rc2
33
+ version: 4.2.0.rc3
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: 4.2.0.rc2
40
+ version: 4.2.0.rc3
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: actionview
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 4.2.0.rc2
47
+ version: 4.2.0.rc3
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 4.2.0.rc2
54
+ version: 4.2.0.rc3
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: activemodel
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - '='
60
60
  - !ruby/object:Gem::Version
61
- version: 4.2.0.rc2
61
+ version: 4.2.0.rc3
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - '='
67
67
  - !ruby/object:Gem::Version
68
- version: 4.2.0.rc2
68
+ version: 4.2.0.rc3
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: activerecord
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - '='
74
74
  - !ruby/object:Gem::Version
75
- version: 4.2.0.rc2
75
+ version: 4.2.0.rc3
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - '='
81
81
  - !ruby/object:Gem::Version
82
- version: 4.2.0.rc2
82
+ version: 4.2.0.rc3
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: actionmailer
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - '='
88
88
  - !ruby/object:Gem::Version
89
- version: 4.2.0.rc2
89
+ version: 4.2.0.rc3
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - '='
95
95
  - !ruby/object:Gem::Version
96
- version: 4.2.0.rc2
96
+ version: 4.2.0.rc3
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: activejob
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - '='
102
102
  - !ruby/object:Gem::Version
103
- version: 4.2.0.rc2
103
+ version: 4.2.0.rc3
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - '='
109
109
  - !ruby/object:Gem::Version
110
- version: 4.2.0.rc2
110
+ version: 4.2.0.rc3
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: railties
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - '='
116
116
  - !ruby/object:Gem::Version
117
- version: 4.2.0.rc2
117
+ version: 4.2.0.rc3
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - '='
123
123
  - !ruby/object:Gem::Version
124
- version: 4.2.0.rc2
124
+ version: 4.2.0.rc3
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: bundler
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
- - - '>='
129
+ - - ">="
130
130
  - !ruby/object:Gem::Version
131
131
  version: 1.3.0
132
- - - <
132
+ - - "<"
133
133
  - !ruby/object:Gem::Version
134
134
  version: '2.0'
135
135
  type: :runtime
136
136
  prerelease: false
137
137
  version_requirements: !ruby/object:Gem::Requirement
138
138
  requirements:
139
- - - '>='
139
+ - - ">="
140
140
  - !ruby/object:Gem::Version
141
141
  version: 1.3.0
142
- - - <
142
+ - - "<"
143
143
  - !ruby/object:Gem::Version
144
144
  version: '2.0'
145
145
  - !ruby/object:Gem::Dependency
146
146
  name: sprockets-rails
147
147
  requirement: !ruby/object:Gem::Requirement
148
148
  requirements:
149
- - - '>='
149
+ - - ">="
150
150
  - !ruby/object:Gem::Version
151
151
  version: '0'
152
152
  type: :runtime
153
153
  prerelease: false
154
154
  version_requirements: !ruby/object:Gem::Requirement
155
155
  requirements:
156
- - - '>='
156
+ - - ">="
157
157
  - !ruby/object:Gem::Version
158
158
  version: '0'
159
159
  description: Ruby on Rails is a full-stack web framework optimized for programmer
@@ -387,17 +387,17 @@ require_paths:
387
387
  - lib
388
388
  required_ruby_version: !ruby/object:Gem::Requirement
389
389
  requirements:
390
- - - '>='
390
+ - - ">="
391
391
  - !ruby/object:Gem::Version
392
392
  version: 1.9.3
393
393
  required_rubygems_version: !ruby/object:Gem::Requirement
394
394
  requirements:
395
- - - '>='
395
+ - - ">="
396
396
  - !ruby/object:Gem::Version
397
397
  version: 1.8.11
398
398
  requirements: []
399
399
  rubyforge_project:
400
- rubygems_version: 2.2.1
400
+ rubygems_version: 2.2.2
401
401
  signing_key:
402
402
  specification_version: 4
403
403
  summary: Full-stack web application framework.