sorbet-rails 0.6.3 → 0.7.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (173) hide show
  1. checksums.yaml +4 -4
  2. data/.gitattributes +1 -2
  3. data/.gitignore +2 -1
  4. data/.travis.yml +3 -1
  5. data/README.md +54 -7
  6. data/Rakefile +3 -3
  7. data/lib/bundled_rbi/customizabel_rbi_formatter.rbi +29 -0
  8. data/lib/bundled_rbi/pluck_to_tstruct.rbi +2 -1
  9. data/lib/bundled_rbi/typed_enum.rbi +7 -0
  10. data/lib/sorbet-rails.rb +1 -3
  11. data/lib/sorbet-rails/active_record_rbi_formatter.rb +8 -2
  12. data/lib/sorbet-rails/config.rb +11 -0
  13. data/lib/sorbet-rails/deprecation.rb +1 -0
  14. data/lib/sorbet-rails/gem_plugins/active_flag_plugin.rb +0 -1
  15. data/lib/sorbet-rails/gem_plugins/kaminari_plugin.rb +8 -0
  16. data/lib/sorbet-rails/gem_plugins/paperclip_plugin.rb +0 -1
  17. data/lib/sorbet-rails/job_rbi_formatter.rb +73 -62
  18. data/lib/sorbet-rails/mailer_rbi_formatter.rb +40 -27
  19. data/lib/sorbet-rails/model_column_utils.rb +129 -0
  20. data/lib/sorbet-rails/model_plugins/active_record_assoc.rb +37 -3
  21. data/lib/sorbet-rails/model_plugins/active_record_attribute.rb +0 -103
  22. data/lib/sorbet-rails/model_plugins/active_record_enum.rb +0 -1
  23. data/lib/sorbet-rails/model_plugins/active_record_named_scope.rb +15 -6
  24. data/lib/sorbet-rails/model_plugins/active_record_querying.rb +34 -3
  25. data/lib/sorbet-rails/model_plugins/active_storage_methods.rb +1 -1
  26. data/lib/sorbet-rails/model_plugins/base.rb +0 -9
  27. data/lib/sorbet-rails/model_rbi_formatter.rb +4 -8
  28. data/lib/sorbet-rails/model_utils.rb +73 -32
  29. data/lib/sorbet-rails/rails_mixins/generated_url_helpers.rb +2 -3
  30. data/lib/sorbet-rails/rails_mixins/pluck_to_tstruct.rb +17 -7
  31. data/lib/sorbet-rails/railtie.rb +0 -2
  32. data/lib/sorbet-rails/sorbet_utils.rb +152 -150
  33. data/lib/sorbet-rails/tasks/rails_rbi.rake +18 -26
  34. data/sorbet-rails.gemspec +1 -1
  35. data/spec/generators/rails-template.rb +3 -6
  36. data/spec/generators/sorbet_test_cases.rb +66 -88
  37. data/spec/job_rbi_formatter_spec.rb +1 -1
  38. data/spec/pluck_to_tstruct_spec.rb +74 -1
  39. data/spec/rails_helper.rb +2 -2
  40. data/spec/rake_rails_rbi_jobs_spec.rb +20 -0
  41. data/spec/rake_rails_rbi_mailers_spec.rb +21 -0
  42. data/spec/support/v5.0/Gemfile +1 -1
  43. data/spec/support/v5.0/Gemfile.lock +9 -9
  44. data/spec/support/v5.0/app/models/spell_book.rb +2 -0
  45. data/spec/support/v5.0/app/models/wizard.rb +1 -1
  46. data/spec/support/v5.0/sorbet_test_cases.rb +66 -88
  47. data/spec/support/v5.1/Gemfile.lock +7 -7
  48. data/spec/support/v5.1/app/models/spell_book.rb +2 -0
  49. data/spec/support/v5.1/app/models/wizard.rb +1 -1
  50. data/spec/support/v5.1/sorbet_test_cases.rb +66 -88
  51. data/spec/support/v5.2/Gemfile +1 -1
  52. data/spec/support/v5.2/Gemfile.lock +9 -9
  53. data/spec/support/v5.2/app/models/spell_book.rb +2 -0
  54. data/spec/support/v5.2/app/models/wizard.rb +1 -1
  55. data/spec/support/v5.2/sorbet_test_cases.rb +66 -88
  56. data/spec/support/v6.0/.gitignore +6 -0
  57. data/spec/support/v6.0/Gemfile +3 -3
  58. data/spec/support/v6.0/Gemfile.lock +77 -76
  59. data/spec/support/v6.0/app/models/spell_book.rb +2 -0
  60. data/spec/support/v6.0/app/models/wizard.rb +1 -1
  61. data/spec/support/v6.0/bin/bundle +22 -13
  62. data/spec/support/v6.0/config/environments/test.rb +1 -1
  63. data/spec/support/v6.0/sorbet_test_cases.rb +66 -88
  64. data/spec/support/v6.0/tmp/pids/.keep +0 -0
  65. data/spec/test_data/v5.0/expected_active_record_base.rbi +2 -2
  66. data/spec/test_data/v5.0/expected_active_record_relation.rbi +2 -2
  67. data/spec/test_data/v5.0/expected_custom_application_job.rbi +21 -0
  68. data/spec/test_data/v5.0/expected_custom_application_mailer.rbi +6 -0
  69. data/spec/test_data/v5.0/expected_custom_award_house_point_hourglasses.rbi +21 -0
  70. data/spec/test_data/v5.0/expected_custom_daily_prophet_mailer.rbi +8 -0
  71. data/spec/test_data/v5.0/expected_custom_hogwarts_acceptance_mailer.rbi +21 -0
  72. data/spec/test_data/v5.0/expected_headmaster.rbi +60 -190
  73. data/spec/test_data/v5.0/expected_internal_metadata.rbi +42 -188
  74. data/spec/test_data/v5.0/expected_potion.rbi +51 -188
  75. data/spec/test_data/v5.0/expected_robe.rbi +51 -190
  76. data/spec/test_data/v5.0/expected_schema_migration.rbi +42 -188
  77. data/spec/test_data/v5.0/expected_school.rbi +51 -190
  78. data/spec/test_data/v5.0/expected_spell.rbi +42 -190
  79. data/spec/test_data/v5.0/expected_spell/habtm_spell_books.rbi +60 -190
  80. data/spec/test_data/v5.0/expected_spell_book.rbi +86 -215
  81. data/spec/test_data/v5.0/expected_spell_book/habtm_spells.rbi +60 -190
  82. data/spec/test_data/v5.0/expected_squib.rbi +131 -263
  83. data/spec/test_data/v5.0/expected_subject.rbi +42 -190
  84. data/spec/test_data/v5.0/expected_subject/habtm_wizards.rbi +60 -190
  85. data/spec/test_data/v5.0/expected_wand.rbi +84 -225
  86. data/spec/test_data/v5.0/expected_wizard.rbi +131 -263
  87. data/spec/test_data/v5.0/expected_wizard/habtm_subjects.rbi +60 -190
  88. data/spec/test_data/v5.0/expected_wizard_wo_spellbook.rbi +131 -263
  89. data/spec/test_data/v5.1/expected_active_record_base.rbi +2 -2
  90. data/spec/test_data/v5.1/expected_active_record_relation.rbi +2 -2
  91. data/spec/test_data/v5.1/expected_custom_application_job.rbi +21 -0
  92. data/spec/test_data/v5.1/expected_custom_application_mailer.rbi +6 -0
  93. data/spec/test_data/v5.1/expected_custom_award_house_point_hourglasses.rbi +21 -0
  94. data/spec/test_data/v5.1/expected_custom_daily_prophet_mailer.rbi +8 -0
  95. data/spec/test_data/v5.1/expected_custom_hogwarts_acceptance_mailer.rbi +21 -0
  96. data/spec/test_data/v5.1/expected_headmaster.rbi +60 -196
  97. data/spec/test_data/v5.1/expected_internal_metadata.rbi +42 -194
  98. data/spec/test_data/v5.1/expected_potion.rbi +51 -194
  99. data/spec/test_data/v5.1/expected_robe.rbi +51 -196
  100. data/spec/test_data/v5.1/expected_schema_migration.rbi +42 -194
  101. data/spec/test_data/v5.1/expected_school.rbi +51 -196
  102. data/spec/test_data/v5.1/expected_spell.rbi +42 -196
  103. data/spec/test_data/v5.1/expected_spell/habtm_spell_books.rbi +60 -196
  104. data/spec/test_data/v5.1/expected_spell_book.rbi +86 -221
  105. data/spec/test_data/v5.1/expected_spell_book/habtm_spells.rbi +60 -196
  106. data/spec/test_data/v5.1/expected_squib.rbi +132 -270
  107. data/spec/test_data/v5.1/expected_subject.rbi +42 -196
  108. data/spec/test_data/v5.1/expected_subject/habtm_wizards.rbi +60 -196
  109. data/spec/test_data/v5.1/expected_wand.rbi +84 -231
  110. data/spec/test_data/v5.1/expected_wizard.rbi +132 -270
  111. data/spec/test_data/v5.1/expected_wizard/habtm_subjects.rbi +60 -196
  112. data/spec/test_data/v5.1/expected_wizard_wo_spellbook.rbi +132 -270
  113. data/spec/test_data/v5.2/expected_active_record_base.rbi +2 -2
  114. data/spec/test_data/v5.2/expected_active_record_relation.rbi +2 -2
  115. data/spec/test_data/v5.2/expected_attachment.rbi +60 -194
  116. data/spec/test_data/v5.2/expected_blob.rbi +80 -214
  117. data/spec/test_data/v5.2/expected_custom_application_job.rbi +21 -0
  118. data/spec/test_data/v5.2/expected_custom_application_mailer.rbi +6 -0
  119. data/spec/test_data/v5.2/expected_custom_award_house_point_hourglasses.rbi +21 -0
  120. data/spec/test_data/v5.2/expected_custom_daily_prophet_mailer.rbi +8 -0
  121. data/spec/test_data/v5.2/expected_custom_hogwarts_acceptance_mailer.rbi +21 -0
  122. data/spec/test_data/v5.2/expected_headmaster.rbi +60 -196
  123. data/spec/test_data/v5.2/expected_internal_metadata.rbi +42 -194
  124. data/spec/test_data/v5.2/expected_potion.rbi +51 -194
  125. data/spec/test_data/v5.2/expected_robe.rbi +51 -196
  126. data/spec/test_data/v5.2/expected_schema_migration.rbi +42 -194
  127. data/spec/test_data/v5.2/expected_school.rbi +51 -196
  128. data/spec/test_data/v5.2/expected_spell.rbi +42 -196
  129. data/spec/test_data/v5.2/expected_spell/habtm_spell_books.rbi +60 -196
  130. data/spec/test_data/v5.2/expected_spell_book.rbi +86 -221
  131. data/spec/test_data/v5.2/expected_spell_book/habtm_spells.rbi +60 -196
  132. data/spec/test_data/v5.2/expected_squib.rbi +156 -276
  133. data/spec/test_data/v5.2/expected_subject.rbi +42 -196
  134. data/spec/test_data/v5.2/expected_subject/habtm_wizards.rbi +60 -196
  135. data/spec/test_data/v5.2/expected_wand.rbi +84 -231
  136. data/spec/test_data/v5.2/expected_wizard.rbi +156 -276
  137. data/spec/test_data/v5.2/expected_wizard/habtm_subjects.rbi +60 -196
  138. data/spec/test_data/v5.2/expected_wizard_wo_spellbook.rbi +156 -276
  139. data/spec/test_data/v6.0/expected_active_record_base.rbi +2 -2
  140. data/spec/test_data/v6.0/expected_active_record_relation.rbi +10 -10
  141. data/spec/test_data/v6.0/expected_attachment.rbi +60 -218
  142. data/spec/test_data/v6.0/expected_blob.rbi +80 -238
  143. data/spec/test_data/v6.0/expected_custom_application_job.rbi +21 -0
  144. data/spec/test_data/v6.0/expected_custom_application_mailer.rbi +6 -0
  145. data/spec/test_data/v6.0/expected_custom_award_house_point_hourglasses.rbi +21 -0
  146. data/spec/test_data/v6.0/expected_custom_daily_prophet_mailer.rbi +8 -0
  147. data/spec/test_data/v6.0/expected_custom_hogwarts_acceptance_mailer.rbi +21 -0
  148. data/spec/test_data/v6.0/expected_headmaster.rbi +60 -220
  149. data/spec/test_data/v6.0/expected_internal_metadata.rbi +42 -218
  150. data/spec/test_data/v6.0/expected_potion.rbi +51 -218
  151. data/spec/test_data/v6.0/expected_robe.rbi +51 -220
  152. data/spec/test_data/v6.0/expected_routes.rbi +14 -7
  153. data/spec/test_data/v6.0/expected_schema_migration.rbi +42 -218
  154. data/spec/test_data/v6.0/expected_school.rbi +51 -220
  155. data/spec/test_data/v6.0/expected_spell.rbi +42 -220
  156. data/spec/test_data/v6.0/expected_spell/habtm_spell_books.rbi +60 -220
  157. data/spec/test_data/v6.0/expected_spell_book.rbi +98 -257
  158. data/spec/test_data/v6.0/expected_spell_book/habtm_spells.rbi +60 -220
  159. data/spec/test_data/v6.0/expected_squib.rbi +182 -326
  160. data/spec/test_data/v6.0/expected_subject.rbi +42 -220
  161. data/spec/test_data/v6.0/expected_subject/habtm_wizards.rbi +60 -220
  162. data/spec/test_data/v6.0/expected_wand.rbi +100 -271
  163. data/spec/test_data/v6.0/expected_wizard.rbi +182 -326
  164. data/spec/test_data/v6.0/expected_wizard/habtm_subjects.rbi +60 -220
  165. data/spec/test_data/v6.0/expected_wizard_wo_spellbook.rbi +182 -326
  166. metadata +46 -11
  167. data/lib/bundled_rbi/parameters.rbi +0 -28
  168. data/lib/sorbet-rails/custom_types/boolean_string.rb +0 -42
  169. data/lib/sorbet-rails/custom_types/integer_string.rb +0 -45
  170. data/lib/sorbet-rails/rails_mixins/custom_params_methods.rb +0 -57
  171. data/spec/boolean_string_spec.rb +0 -59
  172. data/spec/custom_params_methods_spec.rb +0 -138
  173. data/spec/integer_string_spec.rb +0 -46
@@ -0,0 +1,21 @@
1
+ # typed: strong
2
+ # == Custom Generator ==
3
+ # This is an autogenerated file for Rails' jobs.
4
+ # Please rerun bundle exec rake rails_rbi:jobs to regenerate.
5
+ class ApplicationJob
6
+ sig { params(_: T.untyped).void }
7
+ def self.perform_later(*_); end
8
+
9
+ sig { params(_: T.untyped).void }
10
+ def self.perform_now(*_); end
11
+
12
+ sig do
13
+ params(
14
+ wait: T.nilable(ActiveSupport::Duration),
15
+ wait_until: T.nilable(T.any(ActiveSupport::TimeWithZone, Date, Time)),
16
+ queue: T.nilable(T.any(String, Symbol)),
17
+ priority: T.nilable(Integer)
18
+ ).returns(T.self_type)
19
+ end
20
+ def self.set(wait: nil, wait_until: nil, queue: nil, priority: nil); end
21
+ end
@@ -0,0 +1,6 @@
1
+ # typed: strong
2
+ # == Custom Generator ==
3
+ # This is an autogenerated file for Rails' mailers.
4
+ # Please rerun bundle exec rake rails_rbi:mailers to regenerate.
5
+ class ApplicationMailer
6
+ end
@@ -0,0 +1,21 @@
1
+ # typed: strong
2
+ # == Custom Generator ==
3
+ # This is an autogenerated file for Rails' jobs.
4
+ # Please rerun bundle exec rake rails_rbi:jobs to regenerate.
5
+ class AwardHousePointHourglasses
6
+ sig { params(student: Wizard, point: Integer).void }
7
+ def self.perform_later(student:, point:); end
8
+
9
+ sig { params(student: Wizard, point: Integer).void }
10
+ def self.perform_now(student:, point:); end
11
+
12
+ sig do
13
+ params(
14
+ wait: T.nilable(ActiveSupport::Duration),
15
+ wait_until: T.nilable(T.any(ActiveSupport::TimeWithZone, Date, Time)),
16
+ queue: T.nilable(T.any(String, Symbol)),
17
+ priority: T.nilable(Integer)
18
+ ).returns(T.self_type)
19
+ end
20
+ def self.set(wait: nil, wait_until: nil, queue: nil, priority: nil); end
21
+ end
@@ -0,0 +1,8 @@
1
+ # typed: strong
2
+ # == Custom Generator ==
3
+ # This is an autogenerated file for Rails' mailers.
4
+ # Please rerun bundle exec rake rails_rbi:mailers to regenerate.
5
+ class DailyProphetMailer
6
+ sig { params(wizards: T::Array[Wizard], hotnews_only: T::Boolean).returns(ActionMailer::MessageDelivery) }
7
+ def self.notify_subscribers(wizards:, hotnews_only:); end
8
+ end
@@ -0,0 +1,21 @@
1
+ # typed: strong
2
+ # == Custom Generator ==
3
+ # This is an autogenerated file for Rails' mailers.
4
+ # Please rerun bundle exec rake rails_rbi:mailers to regenerate.
5
+ class HogwartsAcceptanceMailer
6
+ sig { params(student: Wizard).returns(ActionMailer::MessageDelivery) }
7
+ def self.notify(student); end
8
+
9
+ sig { params(student: T.untyped).returns(ActionMailer::MessageDelivery) }
10
+ def self.notify_retry(student); end
11
+
12
+ sig do
13
+ params(
14
+ teacher: Wizard,
15
+ note: String,
16
+ student: Wizard,
17
+ special: T::Boolean
18
+ ).returns(ActionMailer::MessageDelivery)
19
+ end
20
+ def self.notify_teacher(teacher, note = nil, student:, special: false); end
21
+ end
@@ -8,8 +8,6 @@ module Headmaster::ActiveRelation_WhereNot
8
8
  end
9
9
 
10
10
  module Headmaster::GeneratedAttributeMethods
11
- extend T::Sig
12
-
13
11
  sig { returns(Integer) }
14
12
  def id; end
15
13
 
@@ -39,17 +37,33 @@ module Headmaster::GeneratedAttributeMethods
39
37
  end
40
38
 
41
39
  module Headmaster::GeneratedAssociationMethods
42
- extend T::Sig
43
-
44
40
  sig { returns(::School) }
45
41
  def school; end
46
42
 
43
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::School).void)).returns(::School) }
44
+ def build_school(*args, &block); end
45
+
46
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::School).void)).returns(::School) }
47
+ def create_school(*args, &block); end
48
+
49
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::School).void)).returns(::School) }
50
+ def create_school!(*args, &block); end
51
+
47
52
  sig { params(value: ::School).void }
48
53
  def school=(value); end
49
54
 
50
55
  sig { returns(::Wizard) }
51
56
  def wizard; end
52
57
 
58
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::Wizard).void)).returns(::Wizard) }
59
+ def build_wizard(*args, &block); end
60
+
61
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::Wizard).void)).returns(::Wizard) }
62
+ def create_wizard(*args, &block); end
63
+
64
+ sig { params(args: T.untyped, block: T.nilable(T.proc.params(object: ::Wizard).void)).returns(::Wizard) }
65
+ def create_wizard!(*args, &block); end
66
+
53
67
  sig { params(value: ::Wizard).void }
54
68
  def wizard=(value); end
55
69
  end
@@ -75,117 +89,11 @@ class Headmaster < ApplicationRecord
75
89
  include Headmaster::GeneratedAttributeMethods
76
90
  include Headmaster::GeneratedAssociationMethods
77
91
  extend Headmaster::CustomFinderMethods
78
- extend T::Sig
79
- extend T::Generic
92
+ extend Headmaster::QueryMethodsReturningRelation
80
93
  RelationType = T.type_alias { T.any(Headmaster::ActiveRecord_Relation, Headmaster::ActiveRecord_Associations_CollectionProxy, Headmaster::ActiveRecord_AssociationRelation) }
81
-
82
- sig { returns(Headmaster::ActiveRecord_Relation) }
83
- def self.all; end
84
-
85
- sig { params(block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_Relation) }
86
- def self.unscoped(&block); end
87
-
88
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
89
- def self.select(*args); end
90
-
91
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
92
- def self.reselect(*args); end
93
-
94
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
95
- def self.order(*args); end
96
-
97
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
98
- def self.reorder(*args); end
99
-
100
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
101
- def self.group(*args); end
102
-
103
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
104
- def self.limit(*args); end
105
-
106
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
107
- def self.offset(*args); end
108
-
109
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
110
- def self.joins(*args); end
111
-
112
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
113
- def self.left_joins(*args); end
114
-
115
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
116
- def self.left_outer_joins(*args); end
117
-
118
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
119
- def self.where(*args); end
120
-
121
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
122
- def self.rewhere(*args); end
123
-
124
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
125
- def self.preload(*args); end
126
-
127
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
128
- def self.extract_associated(*args); end
129
-
130
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
131
- def self.eager_load(*args); end
132
-
133
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
134
- def self.includes(*args); end
135
-
136
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
137
- def self.from(*args); end
138
-
139
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
140
- def self.lock(*args); end
141
-
142
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
143
- def self.readonly(*args); end
144
-
145
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
146
- def self.or(*args); end
147
-
148
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
149
- def self.having(*args); end
150
-
151
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
152
- def self.create_with(*args); end
153
-
154
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
155
- def self.distinct(*args); end
156
-
157
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
158
- def self.references(*args); end
159
-
160
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
161
- def self.none(*args); end
162
-
163
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
164
- def self.unscope(*args); end
165
-
166
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
167
- def self.optimizer_hints(*args); end
168
-
169
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
170
- def self.merge(*args); end
171
-
172
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
173
- def self.except(*args); end
174
-
175
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_Relation) }
176
- def self.only(*args); end
177
-
178
- sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_Relation) }
179
- def self.extending(*args, &block); end
180
94
  end
181
95
 
182
- class Headmaster::ActiveRecord_Relation < ActiveRecord::Relation
183
- include Headmaster::ActiveRelation_WhereNot
184
- include Headmaster::CustomFinderMethods
185
- extend T::Sig
186
- extend T::Generic
187
- Elem = type_member(fixed: Headmaster)
188
-
96
+ module Headmaster::QueryMethodsReturningRelation
189
97
  sig { returns(Headmaster::ActiveRecord_Relation) }
190
98
  def all; end
191
99
 
@@ -284,19 +192,25 @@ class Headmaster::ActiveRecord_Relation < ActiveRecord::Relation
284
192
 
285
193
  sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_Relation) }
286
194
  def extending(*args, &block); end
287
- end
288
195
 
289
- class Headmaster::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
290
- include Headmaster::ActiveRelation_WhereNot
291
- include Headmaster::CustomFinderMethods
292
- extend T::Sig
293
- extend T::Generic
294
- Elem = type_member(fixed: Headmaster)
196
+ sig do
197
+ params(
198
+ of: T.nilable(Integer),
199
+ start: T.nilable(Integer),
200
+ finish: T.nilable(Integer),
201
+ load: T.nilable(T::Boolean),
202
+ error_on_ignore: T.nilable(T::Boolean),
203
+ block: T.nilable(T.proc.params(e: Headmaster::ActiveRecord_Relation).void)
204
+ ).returns(ActiveRecord::Batches::BatchEnumerator)
205
+ end
206
+ def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
207
+ end
295
208
 
209
+ module Headmaster::QueryMethodsReturningAssociationRelation
296
210
  sig { returns(Headmaster::ActiveRecord_AssociationRelation) }
297
211
  def all; end
298
212
 
299
- sig { params(block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_AssociationRelation) }
213
+ sig { params(block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_Relation) }
300
214
  def unscoped(&block); end
301
215
 
302
216
  sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
@@ -391,112 +305,38 @@ class Headmaster::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRe
391
305
 
392
306
  sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_AssociationRelation) }
393
307
  def extending(*args, &block); end
308
+
309
+ sig do
310
+ params(
311
+ of: T.nilable(Integer),
312
+ start: T.nilable(Integer),
313
+ finish: T.nilable(Integer),
314
+ load: T.nilable(T::Boolean),
315
+ error_on_ignore: T.nilable(T::Boolean),
316
+ block: T.nilable(T.proc.params(e: Headmaster::ActiveRecord_AssociationRelation).void)
317
+ ).returns(ActiveRecord::Batches::BatchEnumerator)
318
+ end
319
+ def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
394
320
  end
395
321
 
396
- class Headmaster::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
322
+ class Headmaster::ActiveRecord_Relation < ActiveRecord::Relation
323
+ include Headmaster::ActiveRelation_WhereNot
397
324
  include Headmaster::CustomFinderMethods
398
- extend T::Sig
399
- extend T::Generic
325
+ include Headmaster::QueryMethodsReturningRelation
400
326
  Elem = type_member(fixed: Headmaster)
327
+ end
401
328
 
402
- sig { returns(Headmaster::ActiveRecord_AssociationRelation) }
403
- def all; end
404
-
405
- sig { params(block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_AssociationRelation) }
406
- def unscoped(&block); end
407
-
408
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
409
- def select(*args); end
410
-
411
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
412
- def reselect(*args); end
413
-
414
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
415
- def order(*args); end
416
-
417
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
418
- def reorder(*args); end
419
-
420
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
421
- def group(*args); end
422
-
423
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
424
- def limit(*args); end
425
-
426
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
427
- def offset(*args); end
428
-
429
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
430
- def joins(*args); end
431
-
432
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
433
- def left_joins(*args); end
434
-
435
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
436
- def left_outer_joins(*args); end
437
-
438
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
439
- def where(*args); end
440
-
441
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
442
- def rewhere(*args); end
443
-
444
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
445
- def preload(*args); end
446
-
447
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
448
- def extract_associated(*args); end
449
-
450
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
451
- def eager_load(*args); end
452
-
453
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
454
- def includes(*args); end
455
-
456
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
457
- def from(*args); end
458
-
459
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
460
- def lock(*args); end
461
-
462
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
463
- def readonly(*args); end
464
-
465
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
466
- def or(*args); end
467
-
468
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
469
- def having(*args); end
470
-
471
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
472
- def create_with(*args); end
473
-
474
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
475
- def distinct(*args); end
476
-
477
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
478
- def references(*args); end
479
-
480
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
481
- def none(*args); end
482
-
483
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
484
- def unscope(*args); end
485
-
486
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
487
- def optimizer_hints(*args); end
488
-
489
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
490
- def merge(*args); end
491
-
492
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
493
- def except(*args); end
494
-
495
- sig { params(args: T.untyped).returns(Headmaster::ActiveRecord_AssociationRelation) }
496
- def only(*args); end
329
+ class Headmaster::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
330
+ include Headmaster::ActiveRelation_WhereNot
331
+ include Headmaster::CustomFinderMethods
332
+ include Headmaster::QueryMethodsReturningAssociationRelation
333
+ Elem = type_member(fixed: Headmaster)
334
+ end
497
335
 
498
- sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(Headmaster::ActiveRecord_AssociationRelation) }
499
- def extending(*args, &block); end
336
+ class Headmaster::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
337
+ include Headmaster::CustomFinderMethods
338
+ include Headmaster::QueryMethodsReturningAssociationRelation
339
+ Elem = type_member(fixed: Headmaster)
500
340
 
501
341
  sig { params(records: T.any(Headmaster, T::Array[Headmaster])).returns(T.self_type) }
502
342
  def <<(*records); end
@@ -8,8 +8,6 @@ module ActiveRecord::InternalMetadata::ActiveRelation_WhereNot
8
8
  end
9
9
 
10
10
  module ActiveRecord::InternalMetadata::GeneratedAttributeMethods
11
- extend T::Sig
12
-
13
11
  sig { returns(ActiveSupport::TimeWithZone) }
14
12
  def created_at; end
15
13
 
@@ -67,117 +65,11 @@ end
67
65
  class ActiveRecord::InternalMetadata < ActiveRecord::Base
68
66
  include ActiveRecord::InternalMetadata::GeneratedAttributeMethods
69
67
  extend ActiveRecord::InternalMetadata::CustomFinderMethods
70
- extend T::Sig
71
- extend T::Generic
68
+ extend ActiveRecord::InternalMetadata::QueryMethodsReturningRelation
72
69
  RelationType = T.type_alias { T.any(ActiveRecord::InternalMetadata::ActiveRecord_Relation, ActiveRecord::InternalMetadata::ActiveRecord_Associations_CollectionProxy, ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
73
-
74
- sig { returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
75
- def self.all; end
76
-
77
- sig { params(block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
78
- def self.unscoped(&block); end
79
-
80
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
81
- def self.select(*args); end
82
-
83
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
84
- def self.reselect(*args); end
85
-
86
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
87
- def self.order(*args); end
88
-
89
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
90
- def self.reorder(*args); end
91
-
92
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
93
- def self.group(*args); end
94
-
95
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
96
- def self.limit(*args); end
97
-
98
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
99
- def self.offset(*args); end
100
-
101
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
102
- def self.joins(*args); end
103
-
104
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
105
- def self.left_joins(*args); end
106
-
107
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
108
- def self.left_outer_joins(*args); end
109
-
110
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
111
- def self.where(*args); end
112
-
113
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
114
- def self.rewhere(*args); end
115
-
116
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
117
- def self.preload(*args); end
118
-
119
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
120
- def self.extract_associated(*args); end
121
-
122
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
123
- def self.eager_load(*args); end
124
-
125
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
126
- def self.includes(*args); end
127
-
128
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
129
- def self.from(*args); end
130
-
131
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
132
- def self.lock(*args); end
133
-
134
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
135
- def self.readonly(*args); end
136
-
137
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
138
- def self.or(*args); end
139
-
140
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
141
- def self.having(*args); end
142
-
143
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
144
- def self.create_with(*args); end
145
-
146
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
147
- def self.distinct(*args); end
148
-
149
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
150
- def self.references(*args); end
151
-
152
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
153
- def self.none(*args); end
154
-
155
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
156
- def self.unscope(*args); end
157
-
158
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
159
- def self.optimizer_hints(*args); end
160
-
161
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
162
- def self.merge(*args); end
163
-
164
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
165
- def self.except(*args); end
166
-
167
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
168
- def self.only(*args); end
169
-
170
- sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
171
- def self.extending(*args, &block); end
172
70
  end
173
71
 
174
- class ActiveRecord::InternalMetadata::ActiveRecord_Relation < ActiveRecord::Relation
175
- include ActiveRecord::InternalMetadata::ActiveRelation_WhereNot
176
- include ActiveRecord::InternalMetadata::CustomFinderMethods
177
- extend T::Sig
178
- extend T::Generic
179
- Elem = type_member(fixed: ActiveRecord::InternalMetadata)
180
-
72
+ module ActiveRecord::InternalMetadata::QueryMethodsReturningRelation
181
73
  sig { returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
182
74
  def all; end
183
75
 
@@ -276,19 +168,25 @@ class ActiveRecord::InternalMetadata::ActiveRecord_Relation < ActiveRecord::Rela
276
168
 
277
169
  sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
278
170
  def extending(*args, &block); end
279
- end
280
171
 
281
- class ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
282
- include ActiveRecord::InternalMetadata::ActiveRelation_WhereNot
283
- include ActiveRecord::InternalMetadata::CustomFinderMethods
284
- extend T::Sig
285
- extend T::Generic
286
- Elem = type_member(fixed: ActiveRecord::InternalMetadata)
172
+ sig do
173
+ params(
174
+ of: T.nilable(Integer),
175
+ start: T.nilable(Integer),
176
+ finish: T.nilable(Integer),
177
+ load: T.nilable(T::Boolean),
178
+ error_on_ignore: T.nilable(T::Boolean),
179
+ block: T.nilable(T.proc.params(e: ActiveRecord::InternalMetadata::ActiveRecord_Relation).void)
180
+ ).returns(ActiveRecord::Batches::BatchEnumerator)
181
+ end
182
+ def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
183
+ end
287
184
 
185
+ module ActiveRecord::InternalMetadata::QueryMethodsReturningAssociationRelation
288
186
  sig { returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
289
187
  def all; end
290
188
 
291
- sig { params(block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
189
+ sig { params(block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_Relation) }
292
190
  def unscoped(&block); end
293
191
 
294
192
  sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
@@ -383,112 +281,38 @@ class ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation < ActiveR
383
281
 
384
282
  sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
385
283
  def extending(*args, &block); end
284
+
285
+ sig do
286
+ params(
287
+ of: T.nilable(Integer),
288
+ start: T.nilable(Integer),
289
+ finish: T.nilable(Integer),
290
+ load: T.nilable(T::Boolean),
291
+ error_on_ignore: T.nilable(T::Boolean),
292
+ block: T.nilable(T.proc.params(e: ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation).void)
293
+ ).returns(ActiveRecord::Batches::BatchEnumerator)
294
+ end
295
+ def in_batches(of: 1000, start: nil, finish: nil, load: false, error_on_ignore: nil, &block); end
386
296
  end
387
297
 
388
- class ActiveRecord::InternalMetadata::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
298
+ class ActiveRecord::InternalMetadata::ActiveRecord_Relation < ActiveRecord::Relation
299
+ include ActiveRecord::InternalMetadata::ActiveRelation_WhereNot
389
300
  include ActiveRecord::InternalMetadata::CustomFinderMethods
390
- extend T::Sig
391
- extend T::Generic
301
+ include ActiveRecord::InternalMetadata::QueryMethodsReturningRelation
392
302
  Elem = type_member(fixed: ActiveRecord::InternalMetadata)
303
+ end
393
304
 
394
- sig { returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
395
- def all; end
396
-
397
- sig { params(block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
398
- def unscoped(&block); end
399
-
400
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
401
- def select(*args); end
402
-
403
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
404
- def reselect(*args); end
405
-
406
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
407
- def order(*args); end
408
-
409
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
410
- def reorder(*args); end
411
-
412
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
413
- def group(*args); end
414
-
415
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
416
- def limit(*args); end
417
-
418
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
419
- def offset(*args); end
420
-
421
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
422
- def joins(*args); end
423
-
424
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
425
- def left_joins(*args); end
426
-
427
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
428
- def left_outer_joins(*args); end
429
-
430
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
431
- def where(*args); end
432
-
433
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
434
- def rewhere(*args); end
435
-
436
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
437
- def preload(*args); end
438
-
439
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
440
- def extract_associated(*args); end
441
-
442
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
443
- def eager_load(*args); end
444
-
445
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
446
- def includes(*args); end
447
-
448
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
449
- def from(*args); end
450
-
451
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
452
- def lock(*args); end
453
-
454
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
455
- def readonly(*args); end
456
-
457
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
458
- def or(*args); end
459
-
460
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
461
- def having(*args); end
462
-
463
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
464
- def create_with(*args); end
465
-
466
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
467
- def distinct(*args); end
468
-
469
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
470
- def references(*args); end
471
-
472
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
473
- def none(*args); end
474
-
475
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
476
- def unscope(*args); end
477
-
478
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
479
- def optimizer_hints(*args); end
480
-
481
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
482
- def merge(*args); end
483
-
484
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
485
- def except(*args); end
486
-
487
- sig { params(args: T.untyped).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
488
- def only(*args); end
305
+ class ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation < ActiveRecord::AssociationRelation
306
+ include ActiveRecord::InternalMetadata::ActiveRelation_WhereNot
307
+ include ActiveRecord::InternalMetadata::CustomFinderMethods
308
+ include ActiveRecord::InternalMetadata::QueryMethodsReturningAssociationRelation
309
+ Elem = type_member(fixed: ActiveRecord::InternalMetadata)
310
+ end
489
311
 
490
- sig { params(args: T.untyped, block: T.nilable(T.proc.void)).returns(ActiveRecord::InternalMetadata::ActiveRecord_AssociationRelation) }
491
- def extending(*args, &block); end
312
+ class ActiveRecord::InternalMetadata::ActiveRecord_Associations_CollectionProxy < ActiveRecord::Associations::CollectionProxy
313
+ include ActiveRecord::InternalMetadata::CustomFinderMethods
314
+ include ActiveRecord::InternalMetadata::QueryMethodsReturningAssociationRelation
315
+ Elem = type_member(fixed: ActiveRecord::InternalMetadata)
492
316
 
493
317
  sig { params(records: T.any(ActiveRecord::InternalMetadata, T::Array[ActiveRecord::InternalMetadata])).returns(T.self_type) }
494
318
  def <<(*records); end