sorbet-rails 0.5.5 → 0.5.5.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +7 -1
  3. data/lib/sorbet-rails.rb +2 -0
  4. data/lib/sorbet-rails/custom_types/boolean_string.rb +32 -0
  5. data/lib/sorbet-rails/custom_types/integer_string.rb +35 -0
  6. data/lib/sorbet-rails/model_plugins/active_record_enum.rb +5 -1
  7. data/lib/sorbet-rails/rails_mixins/active_record_overrides.rb +18 -4
  8. data/lib/sorbet-rails/tasks/rails_rbi.rake +1 -2
  9. data/lib/sorbet-rails/type_assert/type_assert.rb +0 -1
  10. data/lib/sorbet-rails/type_assert/type_assert_impl.rb +16 -16
  11. data/sorbet-rails.gemspec +1 -1
  12. data/spec/boolean_string_spec.rb +59 -0
  13. data/spec/generators/rails-template.rb +16 -0
  14. data/spec/integer_string_spec.rb +46 -0
  15. data/spec/rake_rails_rbi_models_spec.rb +1 -0
  16. data/spec/support/v4.2/Gemfile.lock +4 -4
  17. data/spec/support/v4.2/app/models/squib.rb +6 -0
  18. data/spec/support/v4.2/app/models/wizard.rb +1 -2
  19. data/spec/support/v4.2/db/migrate/20190620000007_add_type_to_wizard.rb +6 -0
  20. data/spec/support/v4.2/db/schema.rb +2 -1
  21. data/spec/support/v5.0/Gemfile.lock +4 -4
  22. data/spec/support/v5.0/app/models/squib.rb +6 -0
  23. data/spec/support/v5.0/app/models/wizard.rb +1 -1
  24. data/spec/support/v5.0/db/migrate/20190620000007_add_type_to_wizard.rb +6 -0
  25. data/spec/support/v5.0/db/schema.rb +4 -3
  26. data/spec/support/v5.1/Gemfile.lock +4 -4
  27. data/spec/support/v5.1/app/models/squib.rb +6 -0
  28. data/spec/support/v5.1/app/models/wizard.rb +1 -1
  29. data/spec/support/v5.1/db/migrate/20190620000007_add_type_to_wizard.rb +6 -0
  30. data/spec/support/v5.1/db/schema.rb +2 -1
  31. data/spec/support/v5.2/Gemfile.lock +4 -4
  32. data/spec/support/v5.2/app/models/squib.rb +6 -0
  33. data/spec/support/v5.2/app/models/wizard.rb +1 -1
  34. data/spec/support/v5.2/db/migrate/20190620000007_add_type_to_wizard.rb +6 -0
  35. data/spec/support/v5.2/db/schema.rb +2 -1
  36. data/spec/support/v6.0/Gemfile.lock +5 -5
  37. data/spec/support/v6.0/app/models/squib.rb +6 -0
  38. data/spec/support/v6.0/app/models/wizard.rb +1 -1
  39. data/spec/support/v6.0/db/migrate/20190620000007_add_type_to_wizard.rb +6 -0
  40. data/spec/support/v6.0/db/schema.rb +2 -1
  41. data/spec/test_data/v4.2/expected_squib.rbi +903 -0
  42. data/spec/test_data/v4.2/expected_wizard.rbi +9 -0
  43. data/spec/test_data/v4.2/expected_wizard_wo_spellbook.rbi +9 -0
  44. data/spec/test_data/v5.0/expected_squib.rbi +1164 -0
  45. data/spec/test_data/v5.0/expected_wizard.rbi +9 -0
  46. data/spec/test_data/v5.0/expected_wizard_wo_spellbook.rbi +9 -0
  47. data/spec/test_data/v5.1/expected_squib.rbi +1188 -0
  48. data/spec/test_data/v5.1/expected_wizard.rbi +9 -0
  49. data/spec/test_data/v5.1/expected_wizard_wo_spellbook.rbi +9 -0
  50. data/spec/test_data/v5.2/expected_squib.rbi +1236 -0
  51. data/spec/test_data/v5.2/expected_wizard.rbi +9 -0
  52. data/spec/test_data/v5.2/expected_wizard_wo_spellbook.rbi +9 -0
  53. data/spec/test_data/v6.0/expected_squib.rbi +1500 -0
  54. data/spec/test_data/v6.0/expected_wizard.rbi +9 -0
  55. data/spec/test_data/v6.0/expected_wizard_wo_spellbook.rbi +9 -0
  56. metadata +37 -1
@@ -100,10 +100,10 @@ GEM
100
100
  thor (>= 0.18.1, < 2.0)
101
101
  rainbow (3.0.0)
102
102
  rake (12.3.3)
103
- sorbet (0.4.4709)
104
- sorbet-static (= 0.4.4709)
105
- sorbet-runtime (0.4.4709)
106
- sorbet-static (0.4.4709-universal-darwin-14)
103
+ sorbet (0.4.4755)
104
+ sorbet-static (= 0.4.4755)
105
+ sorbet-runtime (0.4.4755)
106
+ sorbet-static (0.4.4755-universal-darwin-14)
107
107
  sprockets (3.7.2)
108
108
  concurrent-ruby (~> 1.0)
109
109
  rack (> 1, < 3)
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class Squib < Wizard
3
+ def is_magical
4
+ false
5
+ end
6
+ end
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: ignore
2
2
  class Wizard < ApplicationRecord
3
3
  validates :name, length: { minimum: 5 }, presence: true
4
4
 
@@ -0,0 +1,6 @@
1
+ # typed: false
2
+ class AddTypeToWizard < ActiveRecord::Migration[5.0]
3
+ def change
4
+ add_column :wizards, :type, :string, null: false, default: 'Wizard'
5
+ end
6
+ end
@@ -11,7 +11,7 @@
11
11
  #
12
12
  # It's strongly recommended that you check this file into your version control system.
13
13
 
14
- ActiveRecord::Schema.define(version: 20190620000006) do
14
+ ActiveRecord::Schema.define(version: 20190620000007) do
15
15
 
16
16
  create_table "spell_books", force: :cascade do |t|
17
17
  t.string "name"
@@ -40,13 +40,14 @@ ActiveRecord::Schema.define(version: 20190620000006) do
40
40
  t.integer "house"
41
41
  t.string "parent_email"
42
42
  t.text "notes"
43
- t.datetime "created_at", null: false
44
- t.datetime "updated_at", null: false
43
+ t.datetime "created_at", null: false
44
+ t.datetime "updated_at", null: false
45
45
  t.string "broom"
46
46
  t.integer "quidditch_position"
47
47
  t.integer "hair_color"
48
48
  t.integer "eye_color"
49
49
  t.integer "hair_length"
50
+ t.string "type", default: "Wizard", null: false
50
51
  end
51
52
 
52
53
  end
@@ -101,10 +101,10 @@ GEM
101
101
  thor (>= 0.18.1, < 2.0)
102
102
  rainbow (3.0.0)
103
103
  rake (12.3.3)
104
- sorbet (0.4.4709)
105
- sorbet-static (= 0.4.4709)
106
- sorbet-runtime (0.4.4709)
107
- sorbet-static (0.4.4709-universal-darwin-14)
104
+ sorbet (0.4.4755)
105
+ sorbet-static (= 0.4.4755)
106
+ sorbet-runtime (0.4.4755)
107
+ sorbet-static (0.4.4755-universal-darwin-14)
108
108
  sprockets (3.7.2)
109
109
  concurrent-ruby (~> 1.0)
110
110
  rack (> 1, < 3)
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class Squib < Wizard
3
+ def is_magical
4
+ false
5
+ end
6
+ end
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: ignore
2
2
  class Wizard < ApplicationRecord
3
3
  validates :name, length: { minimum: 5 }, presence: true
4
4
 
@@ -0,0 +1,6 @@
1
+ # typed: false
2
+ class AddTypeToWizard < ActiveRecord::Migration[5.1]
3
+ def change
4
+ add_column :wizards, :type, :string, null: false, default: 'Wizard'
5
+ end
6
+ end
@@ -11,7 +11,7 @@
11
11
  #
12
12
  # It's strongly recommended that you check this file into your version control system.
13
13
 
14
- ActiveRecord::Schema.define(version: 20190620000006) do
14
+ ActiveRecord::Schema.define(version: 20190620000007) do
15
15
 
16
16
  create_table "spell_books", force: :cascade do |t|
17
17
  t.string "name"
@@ -47,6 +47,7 @@ ActiveRecord::Schema.define(version: 20190620000006) do
47
47
  t.integer "hair_color"
48
48
  t.integer "eye_color"
49
49
  t.integer "hair_length"
50
+ t.string "type", default: "Wizard", null: false
50
51
  end
51
52
 
52
53
  end
@@ -109,10 +109,10 @@ GEM
109
109
  thor (>= 0.19.0, < 2.0)
110
110
  rainbow (3.0.0)
111
111
  rake (12.3.3)
112
- sorbet (0.4.4709)
113
- sorbet-static (= 0.4.4709)
114
- sorbet-runtime (0.4.4709)
115
- sorbet-static (0.4.4709-universal-darwin-14)
112
+ sorbet (0.4.4755)
113
+ sorbet-static (= 0.4.4755)
114
+ sorbet-runtime (0.4.4755)
115
+ sorbet-static (0.4.4755-universal-darwin-14)
116
116
  sprockets (3.7.2)
117
117
  concurrent-ruby (~> 1.0)
118
118
  rack (> 1, < 3)
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class Squib < Wizard
3
+ def is_magical
4
+ false
5
+ end
6
+ end
@@ -1,4 +1,4 @@
1
- # typed: strict
1
+ # typed: ignore
2
2
  class Wizard < ApplicationRecord
3
3
  validates :name, length: { minimum: 5 }, presence: true
4
4
 
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class AddTypeToWizard < ActiveRecord::Migration[5.2]
3
+ def change
4
+ add_column :wizards, :type, :string, null: false, default: 'Wizard'
5
+ end
6
+ end
@@ -11,7 +11,7 @@
11
11
  #
12
12
  # It's strongly recommended that you check this file into your version control system.
13
13
 
14
- ActiveRecord::Schema.define(version: 2019_06_20_000006) do
14
+ ActiveRecord::Schema.define(version: 2019_06_20_000007) do
15
15
 
16
16
  create_table "spell_books", force: :cascade do |t|
17
17
  t.string "name"
@@ -49,6 +49,7 @@ ActiveRecord::Schema.define(version: 2019_06_20_000006) do
49
49
  t.integer "hair_color"
50
50
  t.integer "eye_color"
51
51
  t.integer "hair_length"
52
+ t.string "type", default: "Wizard", null: false
52
53
  end
53
54
 
54
55
  end
@@ -124,10 +124,10 @@ GEM
124
124
  thor (>= 0.20.3, < 2.0)
125
125
  rainbow (3.0.0)
126
126
  rake (12.3.3)
127
- sorbet (0.4.4709)
128
- sorbet-static (= 0.4.4709)
129
- sorbet-runtime (0.4.4709)
130
- sorbet-static (0.4.4709-universal-darwin-14)
127
+ sorbet (0.4.4755)
128
+ sorbet-static (= 0.4.4755)
129
+ sorbet-runtime (0.4.4755)
130
+ sorbet-static (0.4.4755-universal-darwin-14)
131
131
  sprockets (3.7.2)
132
132
  concurrent-ruby (~> 1.0)
133
133
  rack (> 1, < 3)
@@ -148,7 +148,7 @@ GEM
148
148
  websocket-driver (0.7.1)
149
149
  websocket-extensions (>= 0.1.0)
150
150
  websocket-extensions (0.1.4)
151
- zeitwerk (2.1.9)
151
+ zeitwerk (2.1.10)
152
152
 
153
153
  PLATFORMS
154
154
  ruby
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class Squib < Wizard
3
+ def is_magical
4
+ false
5
+ end
6
+ end
@@ -1,4 +1,4 @@
1
- # typed: false
1
+ # typed: ignore
2
2
  class Wizard < ApplicationRecord
3
3
  validates :name, length: { minimum: 5 }, presence: true
4
4
 
@@ -0,0 +1,6 @@
1
+ # typed: true
2
+ class AddTypeToWizard < ActiveRecord::Migration[6.0]
3
+ def change
4
+ add_column :wizards, :type, :string, null: false, default: 'Wizard'
5
+ end
6
+ end
@@ -11,7 +11,7 @@
11
11
  #
12
12
  # It's strongly recommended that you check this file into your version control system.
13
13
 
14
- ActiveRecord::Schema.define(version: 2019_06_20_000006) do
14
+ ActiveRecord::Schema.define(version: 2019_06_20_000007) do
15
15
 
16
16
  create_table "spell_books", force: :cascade do |t|
17
17
  t.string "name"
@@ -49,6 +49,7 @@ ActiveRecord::Schema.define(version: 2019_06_20_000006) do
49
49
  t.integer "hair_color"
50
50
  t.integer "eye_color"
51
51
  t.integer "hair_length"
52
+ t.string "type", default: "Wizard", null: false
52
53
  end
53
54
 
54
55
  end
@@ -0,0 +1,903 @@
1
+ # This is an autogenerated file for dynamic methods in Squib
2
+ # Please rerun rake rails_rbi:models[Squib] to regenerate.
3
+
4
+ # typed: strong
5
+ module Squib::EnumInstanceMethods
6
+ extend T::Sig
7
+
8
+ sig { returns(T::Boolean) }
9
+ def nimbus?; end
10
+
11
+ sig { void }
12
+ def nimbus!; end
13
+
14
+ sig { returns(T::Boolean) }
15
+ def firebolt?; end
16
+
17
+ sig { void }
18
+ def firebolt!; end
19
+
20
+ sig { returns(T::Boolean) }
21
+ def Gryffindor?; end
22
+
23
+ sig { void }
24
+ def Gryffindor!; end
25
+
26
+ sig { returns(T::Boolean) }
27
+ def Hufflepuff?; end
28
+
29
+ sig { void }
30
+ def Hufflepuff!; end
31
+
32
+ sig { returns(T::Boolean) }
33
+ def Ravenclaw?; end
34
+
35
+ sig { void }
36
+ def Ravenclaw!; end
37
+
38
+ sig { returns(T::Boolean) }
39
+ def Slytherin?; end
40
+
41
+ sig { void }
42
+ def Slytherin!; end
43
+
44
+ sig { returns(T::Boolean) }
45
+ def Hagrid?; end
46
+
47
+ sig { void }
48
+ def Hagrid!; end
49
+ end
50
+
51
+ module Squib::ActiveRelation_WhereNot
52
+ sig { params(opts: T.untyped, rest: T.untyped).returns(T.self_type) }
53
+ def not(opts, *rest); end
54
+ end
55
+
56
+ module Squib::GeneratedAttributeMethods
57
+ extend T::Sig
58
+
59
+ sig { returns(T.nilable(String)) }
60
+ def broom; end
61
+
62
+ sig { params(value: T.nilable(T.any(Integer, String, Symbol))).void }
63
+ def broom=(value); end
64
+
65
+ sig { returns(T::Boolean) }
66
+ def broom?; end
67
+
68
+ sig { returns(T.nilable(Time)) }
69
+ def created_at; end
70
+
71
+ sig { params(value: T.nilable(Time)).void }
72
+ def created_at=(value); end
73
+
74
+ sig { returns(T::Boolean) }
75
+ def created_at?; end
76
+
77
+ sig { returns(T.nilable(String)) }
78
+ def house; end
79
+
80
+ sig { params(value: T.nilable(T.any(Integer, String, Symbol))).void }
81
+ def house=(value); end
82
+
83
+ sig { returns(T::Boolean) }
84
+ def house?; end
85
+
86
+ sig { returns(Integer) }
87
+ def id; end
88
+
89
+ sig { params(value: Integer).void }
90
+ def id=(value); end
91
+
92
+ sig { returns(T::Boolean) }
93
+ def id?; end
94
+
95
+ sig { returns(T.nilable(String)) }
96
+ def name; end
97
+
98
+ sig { params(value: T.nilable(String)).void }
99
+ def name=(value); end
100
+
101
+ sig { returns(T::Boolean) }
102
+ def name?; end
103
+
104
+ sig { returns(T.nilable(String)) }
105
+ def notes; end
106
+
107
+ sig { params(value: T.nilable(String)).void }
108
+ def notes=(value); end
109
+
110
+ sig { returns(T::Boolean) }
111
+ def notes?; end
112
+
113
+ sig { returns(T.nilable(String)) }
114
+ def parent_email; end
115
+
116
+ sig { params(value: T.nilable(String)).void }
117
+ def parent_email=(value); end
118
+
119
+ sig { returns(T::Boolean) }
120
+ def parent_email?; end
121
+
122
+ sig { returns(String) }
123
+ def type; end
124
+
125
+ sig { params(value: String).void }
126
+ def type=(value); end
127
+
128
+ sig { returns(T::Boolean) }
129
+ def type?; end
130
+
131
+ sig { returns(T.nilable(Time)) }
132
+ def updated_at; end
133
+
134
+ sig { params(value: T.nilable(Time)).void }
135
+ def updated_at=(value); end
136
+
137
+ sig { returns(T::Boolean) }
138
+ def updated_at?; end
139
+ end
140
+
141
+ module Squib::GeneratedAssociationMethods
142
+ extend T::Sig
143
+
144
+ sig { returns(::SpellBook::ActiveRecord_Associations_CollectionProxy) }
145
+ def spell_books; end
146
+
147
+ sig { params(value: T.any(T::Array[::SpellBook], ::SpellBook::ActiveRecord_Associations_CollectionProxy)).void }
148
+ def spell_books=(value); end
149
+
150
+ sig { returns(T.nilable(::Wand)) }
151
+ def wand; end
152
+
153
+ sig { params(value: T.nilable(::Wand)).void }
154
+ def wand=(value); end
155
+ end
156
+
157
+ module Squib::CustomFinderMethods
158
+ sig { params(limit: Integer).returns(T::Array[Squib]) }
159
+ def first_n(limit); end
160
+
161
+ sig { params(limit: Integer).returns(T::Array[Squib]) }
162
+ def last_n(limit); end
163
+
164
+ sig { params(args: T::Array[T.any(Integer, String)]).returns(T::Array[Squib]) }
165
+ def find_n(*args); end
166
+
167
+ sig { params(id: Integer).returns(T.nilable(Squib)) }
168
+ def find_by_id(id); end
169
+
170
+ sig { params(id: Integer).returns(Squib) }
171
+ def find_by_id!(id); end
172
+ end
173
+
174
+ class Squib < Wizard
175
+ include Squib::EnumInstanceMethods
176
+ include Squib::GeneratedAttributeMethods
177
+ include Squib::GeneratedAssociationMethods
178
+ extend Squib::CustomFinderMethods
179
+ extend T::Sig
180
+ extend T::Generic
181
+
182
+ sig { returns(T::Hash[T.any(String, Symbol), String]) }
183
+ def self.brooms; end
184
+
185
+ sig { returns(T::Hash[T.any(String, Symbol), Integer]) }
186
+ def self.houses; end
187
+
188
+ sig { returns(T::Hash[T.any(String, Symbol), Integer]) }
189
+ def self.professors; end
190
+
191
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
192
+ def self.Gryffindor(*args); end
193
+
194
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
195
+ def self.Hagrid(*args); end
196
+
197
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
198
+ def self.Hufflepuff(*args); end
199
+
200
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
201
+ def self.Ravenclaw(*args); end
202
+
203
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
204
+ def self.Slytherin(*args); end
205
+
206
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
207
+ def self.firebolt(*args); end
208
+
209
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
210
+ def self.nimbus(*args); end
211
+
212
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
213
+ def self.recent(*args); end
214
+
215
+ sig { returns(Squib::ActiveRecord_Relation) }
216
+ def self.all; end
217
+
218
+ sig { params(block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
219
+ def self.unscoped(&block); end
220
+
221
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
222
+ def self.select(*args, &block); end
223
+
224
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
225
+ def self.order(*args, &block); end
226
+
227
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
228
+ def self.reorder(*args, &block); end
229
+
230
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
231
+ def self.group(*args, &block); end
232
+
233
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
234
+ def self.limit(*args, &block); end
235
+
236
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
237
+ def self.offset(*args, &block); end
238
+
239
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
240
+ def self.joins(*args, &block); end
241
+
242
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
243
+ def self.where(*args, &block); end
244
+
245
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
246
+ def self.rewhere(*args, &block); end
247
+
248
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
249
+ def self.preload(*args, &block); end
250
+
251
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
252
+ def self.eager_load(*args, &block); end
253
+
254
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
255
+ def self.includes(*args, &block); end
256
+
257
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
258
+ def self.from(*args, &block); end
259
+
260
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
261
+ def self.lock(*args, &block); end
262
+
263
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
264
+ def self.readonly(*args, &block); end
265
+
266
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
267
+ def self.having(*args, &block); end
268
+
269
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
270
+ def self.create_with(*args, &block); end
271
+
272
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
273
+ def self.distinct(*args, &block); end
274
+
275
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
276
+ def self.references(*args, &block); end
277
+
278
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
279
+ def self.none(*args, &block); end
280
+
281
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
282
+ def self.unscope(*args, &block); end
283
+
284
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
285
+ def self.except(*args, &block); end
286
+
287
+ sig { params(args: T.untyped).returns(Squib) }
288
+ def self.find(*args); end
289
+
290
+ sig { params(args: T.untyped).returns(T.nilable(Squib)) }
291
+ def self.find_by(*args); end
292
+
293
+ sig { params(args: T.untyped).returns(Squib) }
294
+ def self.find_by!(*args); end
295
+
296
+ sig { returns(T.nilable(Squib)) }
297
+ def self.first; end
298
+
299
+ sig { returns(Squib) }
300
+ def self.first!; end
301
+
302
+ sig { returns(T.nilable(Squib)) }
303
+ def self.second; end
304
+
305
+ sig { returns(Squib) }
306
+ def self.second!; end
307
+
308
+ sig { returns(T.nilable(Squib)) }
309
+ def self.third; end
310
+
311
+ sig { returns(Squib) }
312
+ def self.third!; end
313
+
314
+ sig { returns(T.nilable(Squib)) }
315
+ def self.third_to_last; end
316
+
317
+ sig { returns(Squib) }
318
+ def self.third_to_last!; end
319
+
320
+ sig { returns(T.nilable(Squib)) }
321
+ def self.second_to_last; end
322
+
323
+ sig { returns(Squib) }
324
+ def self.second_to_last!; end
325
+
326
+ sig { returns(T.nilable(Squib)) }
327
+ def self.last; end
328
+
329
+ sig { returns(Squib) }
330
+ def self.last!; end
331
+
332
+ sig { params(conditions: T.untyped).returns(T::Boolean) }
333
+ def self.exists?(conditions = nil); end
334
+
335
+ sig { params(args: T.untyped).returns(T::Boolean) }
336
+ def self.any?(*args); end
337
+
338
+ sig { params(args: T.untyped).returns(T::Boolean) }
339
+ def self.many?(*args); end
340
+
341
+ sig { params(args: T.untyped).returns(T::Boolean) }
342
+ def self.none?(*args); end
343
+
344
+ sig { params(args: T.untyped).returns(T::Boolean) }
345
+ def self.one?(*args); end
346
+ end
347
+
348
+ class Squib::ActiveRecord_Relation < ActiveRecord::Relation
349
+ include Squib::ActiveRelation_WhereNot
350
+ include Squib::CustomFinderMethods
351
+ include Enumerable
352
+ extend T::Sig
353
+ extend T::Generic
354
+ Elem = type_member(fixed: Squib)
355
+
356
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
357
+ def Gryffindor(*args); end
358
+
359
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
360
+ def Hagrid(*args); end
361
+
362
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
363
+ def Hufflepuff(*args); end
364
+
365
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
366
+ def Ravenclaw(*args); end
367
+
368
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
369
+ def Slytherin(*args); end
370
+
371
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
372
+ def firebolt(*args); end
373
+
374
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
375
+ def nimbus(*args); end
376
+
377
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_Relation) }
378
+ def recent(*args); end
379
+
380
+ sig { returns(Squib::ActiveRecord_Relation) }
381
+ def all; end
382
+
383
+ sig { params(block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
384
+ def unscoped(&block); end
385
+
386
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
387
+ def select(*args, &block); end
388
+
389
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
390
+ def order(*args, &block); end
391
+
392
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
393
+ def reorder(*args, &block); end
394
+
395
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
396
+ def group(*args, &block); end
397
+
398
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
399
+ def limit(*args, &block); end
400
+
401
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
402
+ def offset(*args, &block); end
403
+
404
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
405
+ def joins(*args, &block); end
406
+
407
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
408
+ def where(*args, &block); end
409
+
410
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
411
+ def rewhere(*args, &block); end
412
+
413
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
414
+ def preload(*args, &block); end
415
+
416
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
417
+ def eager_load(*args, &block); end
418
+
419
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
420
+ def includes(*args, &block); end
421
+
422
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
423
+ def from(*args, &block); end
424
+
425
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
426
+ def lock(*args, &block); end
427
+
428
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
429
+ def readonly(*args, &block); end
430
+
431
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
432
+ def having(*args, &block); end
433
+
434
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
435
+ def create_with(*args, &block); end
436
+
437
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
438
+ def distinct(*args, &block); end
439
+
440
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
441
+ def references(*args, &block); end
442
+
443
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
444
+ def none(*args, &block); end
445
+
446
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
447
+ def unscope(*args, &block); end
448
+
449
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_Relation) }
450
+ def except(*args, &block); end
451
+
452
+ sig { params(args: T.untyped).returns(Squib) }
453
+ def find(*args); end
454
+
455
+ sig { params(args: T.untyped).returns(T.nilable(Squib)) }
456
+ def find_by(*args); end
457
+
458
+ sig { params(args: T.untyped).returns(Squib) }
459
+ def find_by!(*args); end
460
+
461
+ sig { returns(T.nilable(Squib)) }
462
+ def first; end
463
+
464
+ sig { returns(Squib) }
465
+ def first!; end
466
+
467
+ sig { returns(T.nilable(Squib)) }
468
+ def second; end
469
+
470
+ sig { returns(Squib) }
471
+ def second!; end
472
+
473
+ sig { returns(T.nilable(Squib)) }
474
+ def third; end
475
+
476
+ sig { returns(Squib) }
477
+ def third!; end
478
+
479
+ sig { returns(T.nilable(Squib)) }
480
+ def third_to_last; end
481
+
482
+ sig { returns(Squib) }
483
+ def third_to_last!; end
484
+
485
+ sig { returns(T.nilable(Squib)) }
486
+ def second_to_last; end
487
+
488
+ sig { returns(Squib) }
489
+ def second_to_last!; end
490
+
491
+ sig { returns(T.nilable(Squib)) }
492
+ def last; end
493
+
494
+ sig { returns(Squib) }
495
+ def last!; end
496
+
497
+ sig { params(conditions: T.untyped).returns(T::Boolean) }
498
+ def exists?(conditions = nil); end
499
+
500
+ sig { params(args: T.untyped).returns(T::Boolean) }
501
+ def any?(*args); end
502
+
503
+ sig { params(args: T.untyped).returns(T::Boolean) }
504
+ def many?(*args); end
505
+
506
+ sig { params(args: T.untyped).returns(T::Boolean) }
507
+ def none?(*args); end
508
+
509
+ sig { params(args: T.untyped).returns(T::Boolean) }
510
+ def one?(*args); end
511
+
512
+ sig { override.params(block: T.proc.params(e: Squib).void).void }
513
+ def each(&block); end
514
+
515
+ sig { params(level: T.nilable(Integer)).returns(T::Array[Squib]) }
516
+ def flatten(level); end
517
+
518
+ sig { returns(T::Array[Squib]) }
519
+ def to_a; end
520
+
521
+ sig do
522
+ type_parameters(:U).params(
523
+ blk: T.proc.params(arg0: Elem).returns(T.type_parameter(:U)),
524
+ )
525
+ .returns(T::Array[T.type_parameter(:U)])
526
+ end
527
+ def map(&blk); end
528
+ end
529
+
530
+ class Squib::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
531
+ include Squib::ActiveRelation_WhereNot
532
+ include Squib::CustomFinderMethods
533
+ include Enumerable
534
+ extend T::Sig
535
+ extend T::Generic
536
+ Elem = type_member(fixed: Squib)
537
+
538
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
539
+ def Gryffindor(*args); end
540
+
541
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
542
+ def Hagrid(*args); end
543
+
544
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
545
+ def Hufflepuff(*args); end
546
+
547
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
548
+ def Ravenclaw(*args); end
549
+
550
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
551
+ def Slytherin(*args); end
552
+
553
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
554
+ def firebolt(*args); end
555
+
556
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
557
+ def nimbus(*args); end
558
+
559
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
560
+ def recent(*args); end
561
+
562
+ sig { returns(Squib::ActiveRecord_AssociationRelation) }
563
+ def all; end
564
+
565
+ sig { params(block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
566
+ def unscoped(&block); end
567
+
568
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
569
+ def select(*args, &block); end
570
+
571
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
572
+ def order(*args, &block); end
573
+
574
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
575
+ def reorder(*args, &block); end
576
+
577
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
578
+ def group(*args, &block); end
579
+
580
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
581
+ def limit(*args, &block); end
582
+
583
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
584
+ def offset(*args, &block); end
585
+
586
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
587
+ def joins(*args, &block); end
588
+
589
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
590
+ def where(*args, &block); end
591
+
592
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
593
+ def rewhere(*args, &block); end
594
+
595
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
596
+ def preload(*args, &block); end
597
+
598
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
599
+ def eager_load(*args, &block); end
600
+
601
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
602
+ def includes(*args, &block); end
603
+
604
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
605
+ def from(*args, &block); end
606
+
607
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
608
+ def lock(*args, &block); end
609
+
610
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
611
+ def readonly(*args, &block); end
612
+
613
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
614
+ def having(*args, &block); end
615
+
616
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
617
+ def create_with(*args, &block); end
618
+
619
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
620
+ def distinct(*args, &block); end
621
+
622
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
623
+ def references(*args, &block); end
624
+
625
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
626
+ def none(*args, &block); end
627
+
628
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
629
+ def unscope(*args, &block); end
630
+
631
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
632
+ def except(*args, &block); end
633
+
634
+ sig { params(args: T.untyped).returns(Squib) }
635
+ def find(*args); end
636
+
637
+ sig { params(args: T.untyped).returns(T.nilable(Squib)) }
638
+ def find_by(*args); end
639
+
640
+ sig { params(args: T.untyped).returns(Squib) }
641
+ def find_by!(*args); end
642
+
643
+ sig { returns(T.nilable(Squib)) }
644
+ def first; end
645
+
646
+ sig { returns(Squib) }
647
+ def first!; end
648
+
649
+ sig { returns(T.nilable(Squib)) }
650
+ def second; end
651
+
652
+ sig { returns(Squib) }
653
+ def second!; end
654
+
655
+ sig { returns(T.nilable(Squib)) }
656
+ def third; end
657
+
658
+ sig { returns(Squib) }
659
+ def third!; end
660
+
661
+ sig { returns(T.nilable(Squib)) }
662
+ def third_to_last; end
663
+
664
+ sig { returns(Squib) }
665
+ def third_to_last!; end
666
+
667
+ sig { returns(T.nilable(Squib)) }
668
+ def second_to_last; end
669
+
670
+ sig { returns(Squib) }
671
+ def second_to_last!; end
672
+
673
+ sig { returns(T.nilable(Squib)) }
674
+ def last; end
675
+
676
+ sig { returns(Squib) }
677
+ def last!; end
678
+
679
+ sig { params(conditions: T.untyped).returns(T::Boolean) }
680
+ def exists?(conditions = nil); end
681
+
682
+ sig { params(args: T.untyped).returns(T::Boolean) }
683
+ def any?(*args); end
684
+
685
+ sig { params(args: T.untyped).returns(T::Boolean) }
686
+ def many?(*args); end
687
+
688
+ sig { params(args: T.untyped).returns(T::Boolean) }
689
+ def none?(*args); end
690
+
691
+ sig { params(args: T.untyped).returns(T::Boolean) }
692
+ def one?(*args); end
693
+
694
+ sig { override.params(block: T.proc.params(e: Squib).void).void }
695
+ def each(&block); end
696
+
697
+ sig { params(level: T.nilable(Integer)).returns(T::Array[Squib]) }
698
+ def flatten(level); end
699
+
700
+ sig { returns(T::Array[Squib]) }
701
+ def to_a; end
702
+
703
+ sig do
704
+ type_parameters(:U).params(
705
+ blk: T.proc.params(arg0: Elem).returns(T.type_parameter(:U)),
706
+ )
707
+ .returns(T::Array[T.type_parameter(:U)])
708
+ end
709
+ def map(&blk); end
710
+ end
711
+
712
+ class Squib::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
713
+ include Squib::CustomFinderMethods
714
+ include Enumerable
715
+ extend T::Sig
716
+ extend T::Generic
717
+ Elem = type_member(fixed: Squib)
718
+
719
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
720
+ def Gryffindor(*args); end
721
+
722
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
723
+ def Hagrid(*args); end
724
+
725
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
726
+ def Hufflepuff(*args); end
727
+
728
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
729
+ def Ravenclaw(*args); end
730
+
731
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
732
+ def Slytherin(*args); end
733
+
734
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
735
+ def firebolt(*args); end
736
+
737
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
738
+ def nimbus(*args); end
739
+
740
+ sig { params(args: T.untyped).returns(Squib::ActiveRecord_AssociationRelation) }
741
+ def recent(*args); end
742
+
743
+ sig { returns(Squib::ActiveRecord_AssociationRelation) }
744
+ def all; end
745
+
746
+ sig { params(block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
747
+ def unscoped(&block); end
748
+
749
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
750
+ def select(*args, &block); end
751
+
752
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
753
+ def order(*args, &block); end
754
+
755
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
756
+ def reorder(*args, &block); end
757
+
758
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
759
+ def group(*args, &block); end
760
+
761
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
762
+ def limit(*args, &block); end
763
+
764
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
765
+ def offset(*args, &block); end
766
+
767
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
768
+ def joins(*args, &block); end
769
+
770
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
771
+ def where(*args, &block); end
772
+
773
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
774
+ def rewhere(*args, &block); end
775
+
776
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
777
+ def preload(*args, &block); end
778
+
779
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
780
+ def eager_load(*args, &block); end
781
+
782
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
783
+ def includes(*args, &block); end
784
+
785
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
786
+ def from(*args, &block); end
787
+
788
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
789
+ def lock(*args, &block); end
790
+
791
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
792
+ def readonly(*args, &block); end
793
+
794
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
795
+ def having(*args, &block); end
796
+
797
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
798
+ def create_with(*args, &block); end
799
+
800
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
801
+ def distinct(*args, &block); end
802
+
803
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
804
+ def references(*args, &block); end
805
+
806
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
807
+ def none(*args, &block); end
808
+
809
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
810
+ def unscope(*args, &block); end
811
+
812
+ sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Squib::ActiveRecord_AssociationRelation) }
813
+ def except(*args, &block); end
814
+
815
+ sig { params(args: T.untyped).returns(Squib) }
816
+ def find(*args); end
817
+
818
+ sig { params(args: T.untyped).returns(T.nilable(Squib)) }
819
+ def find_by(*args); end
820
+
821
+ sig { params(args: T.untyped).returns(Squib) }
822
+ def find_by!(*args); end
823
+
824
+ sig { returns(T.nilable(Squib)) }
825
+ def first; end
826
+
827
+ sig { returns(Squib) }
828
+ def first!; end
829
+
830
+ sig { returns(T.nilable(Squib)) }
831
+ def second; end
832
+
833
+ sig { returns(Squib) }
834
+ def second!; end
835
+
836
+ sig { returns(T.nilable(Squib)) }
837
+ def third; end
838
+
839
+ sig { returns(Squib) }
840
+ def third!; end
841
+
842
+ sig { returns(T.nilable(Squib)) }
843
+ def third_to_last; end
844
+
845
+ sig { returns(Squib) }
846
+ def third_to_last!; end
847
+
848
+ sig { returns(T.nilable(Squib)) }
849
+ def second_to_last; end
850
+
851
+ sig { returns(Squib) }
852
+ def second_to_last!; end
853
+
854
+ sig { returns(T.nilable(Squib)) }
855
+ def last; end
856
+
857
+ sig { returns(Squib) }
858
+ def last!; end
859
+
860
+ sig { params(conditions: T.untyped).returns(T::Boolean) }
861
+ def exists?(conditions = nil); end
862
+
863
+ sig { params(args: T.untyped).returns(T::Boolean) }
864
+ def any?(*args); end
865
+
866
+ sig { params(args: T.untyped).returns(T::Boolean) }
867
+ def many?(*args); end
868
+
869
+ sig { params(args: T.untyped).returns(T::Boolean) }
870
+ def none?(*args); end
871
+
872
+ sig { params(args: T.untyped).returns(T::Boolean) }
873
+ def one?(*args); end
874
+
875
+ sig { override.params(block: T.proc.params(e: Squib).void).void }
876
+ def each(&block); end
877
+
878
+ sig { params(level: T.nilable(Integer)).returns(T::Array[Squib]) }
879
+ def flatten(level); end
880
+
881
+ sig { returns(T::Array[Squib]) }
882
+ def to_a; end
883
+
884
+ sig do
885
+ type_parameters(:U).params(
886
+ blk: T.proc.params(arg0: Elem).returns(T.type_parameter(:U)),
887
+ )
888
+ .returns(T::Array[T.type_parameter(:U)])
889
+ end
890
+ def map(&blk); end
891
+
892
+ sig { params(records: T.any(Squib, T::Array[Squib])).returns(T.self_type) }
893
+ def <<(*records); end
894
+
895
+ sig { params(records: T.any(Squib, T::Array[Squib])).returns(T.self_type) }
896
+ def append(*records); end
897
+
898
+ sig { params(records: T.any(Squib, T::Array[Squib])).returns(T.self_type) }
899
+ def push(*records); end
900
+
901
+ sig { params(records: T.any(Squib, T::Array[Squib])).returns(T.self_type) }
902
+ def concat(*records); end
903
+ end