We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7e68f5c commit f976ea6Copy full SHA for f976ea6
lib/tapioca/dsl/pipeline.rb
@@ -225,9 +225,14 @@ def report_error(error)
225
226
sig { void }
227
def abort_if_pending_migrations!
228
+ # When running within the add-on, we cannot invoke the abort if pending migrations task because that will exit
229
+ # the process and crash the Rails runtime server. Instead, the Rails add-on checks for pending migrations and
230
+ # warns the user, so that they are aware they need to migrate their database
231
+ return if @lsp_addon
232
return unless defined?(::Rake)
233
234
Rails.application.load_tasks
235
+
236
if Rake::Task.task_defined?("db:abort_if_pending_migrations")
237
Rake::Task["db:abort_if_pending_migrations"].invoke
238
end
0 commit comments