columns_on_demand 5.1.2 → 5.2.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 +5 -5
- data/MIT-LICENSE +1 -1
- data/README.md +2 -2
- data/columns_on_demand.gemspec +0 -1
- data/lib/columns_on_demand.rb +14 -1
- data/lib/columns_on_demand/version.rb +1 -1
- data/test_all.sh +11 -0
- metadata +3 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: c35479e9e268cbc8b33a8b981e28728a76745894e3dd91ca4fcbc92903fcd1b4
|
4
|
+
data.tar.gz: cc6bc4f1ed2476f225d40fd3aa74f47ab1ef8041661efda8e4ba4a2cb41d4fef
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0f48f8af4a0cdfcaac66e0169467125513fc54d9995dc8e798d06ed9b30901196ad2a14959622afec8579ba4306545d766d4f48a197b888360feb951c2f4f314
|
7
|
+
data.tar.gz: 48643342903f8b5d04d69d27f3a5573a78d776f72f6fbdfdcb3f3287e60c016c08b1223cce6c7d0ccd70383ed1a5dad116979e48def4ee340435f3595a02330e
|
data/MIT-LICENSE
CHANGED
data/README.md
CHANGED
@@ -21,7 +21,7 @@ Compatibility
|
|
21
21
|
|
22
22
|
Supports mysql, mysql2, postgresql, and sqlite3.
|
23
23
|
|
24
|
-
Currently tested against Rails 5.1 (up to 5.1.4), 5.0 (up to 5.0.6), and 4.2 (up to 4.2.10), on Ruby 2.3.4.
|
24
|
+
Currently tested against Rails 5.2 (up to 5.2.0.beta2), 5.1 (up to 5.1.4), 5.0 (up to 5.0.6), and 4.2 (up to 4.2.10), on Ruby 2.3.6, 2.4.3, and 2.5.0.
|
25
25
|
|
26
26
|
For earlier versions of Rails, use an older version of the gem.
|
27
27
|
|
@@ -54,4 +54,4 @@ Thanks
|
|
54
54
|
* Tobias Matthies (@tobmatth)
|
55
55
|
* Phil Ross (@philr)
|
56
56
|
|
57
|
-
Copyright (c) 2008-
|
57
|
+
Copyright (c) 2008-2018 Will Bryant, Sekuda Ltd, released under the MIT license
|
data/columns_on_demand.gemspec
CHANGED
data/lib/columns_on_demand.rb
CHANGED
@@ -149,7 +149,7 @@ ActiveRecord::Relation.send(:prepend, ColumnsOnDemand::RelationMethods)
|
|
149
149
|
# (due to dirty.rb mapping @attributes). this is not only a problem for columns_on_demand as it
|
150
150
|
# means that a MissingAttributeError will never be raised after save, but we suffer more.
|
151
151
|
# ActiveRecord 4.2's Attribute doesn't have forgetting_assignment (or this problem).
|
152
|
-
if ActiveRecord::Attribute.uninitialized(nil, nil).try(:forgetting_assignment).try(:initialized?)
|
152
|
+
if ActiveRecord.const_defined?(:Attribute) && ActiveRecord::Attribute.uninitialized(nil, nil).try(:forgetting_assignment).try(:initialized?)
|
153
153
|
module ActiveRecord
|
154
154
|
class Attribute # :nodoc:
|
155
155
|
class Uninitialized < Attribute # :nodoc:
|
@@ -160,3 +160,16 @@ if ActiveRecord::Attribute.uninitialized(nil, nil).try(:forgetting_assignment).t
|
|
160
160
|
end
|
161
161
|
end
|
162
162
|
end
|
163
|
+
|
164
|
+
# same for 5.2
|
165
|
+
if ActiveModel.const_defined?(:Attribute) && ActiveModel::Attribute.uninitialized(nil, nil).try(:forgetting_assignment).try(:initialized?)
|
166
|
+
module ActiveModel
|
167
|
+
class Attribute # :nodoc:
|
168
|
+
class Uninitialized < Attribute # :nodoc:
|
169
|
+
def forgetting_assignment
|
170
|
+
dup
|
171
|
+
end
|
172
|
+
end
|
173
|
+
end
|
174
|
+
end
|
175
|
+
end
|
data/test_all.sh
ADDED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: columns_on_demand
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Will Bryant
|
@@ -38,20 +38,6 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: mysql
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ">="
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
48
|
-
type: :development
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ">="
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
55
41
|
- !ruby/object:Gem::Dependency
|
56
42
|
name: mysql2
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -152,6 +138,7 @@ files:
|
|
152
138
|
- test/fixtures/parents.yml
|
153
139
|
- test/schema.rb
|
154
140
|
- test/test_helper.rb
|
141
|
+
- test_all.sh
|
155
142
|
homepage: http://github.com/willbryant/columns_on_demand
|
156
143
|
licenses:
|
157
144
|
- MIT
|
@@ -172,7 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
172
159
|
version: '0'
|
173
160
|
requirements: []
|
174
161
|
rubyforge_project:
|
175
|
-
rubygems_version: 2.
|
162
|
+
rubygems_version: 2.7.3
|
176
163
|
signing_key:
|
177
164
|
specification_version: 4
|
178
165
|
summary: Lazily loads large columns on demand.
|
@@ -185,4 +172,3 @@ test_files:
|
|
185
172
|
- test/fixtures/parents.yml
|
186
173
|
- test/schema.rb
|
187
174
|
- test/test_helper.rb
|
188
|
-
has_rdoc: false
|