Skip to content
Snippets Groups Projects
Unverified Commit 93d34aad authored by Samuel Couillard's avatar Samuel Couillard Committed by GitHub
Browse files

Add Errors Logs to Migration (v2) (#4678)

* Add Errors logging to Migration (v2)

* Improve error logging

* rubo

* Fix last line removal mistake
parent 83bb0a92
No related branches found
No related tags found
No related merge requests found
......@@ -45,6 +45,7 @@ namespace :migrations do
puts red "Unable to migrate Role:"
puts yellow "ID: #{r.id}"
puts yellow "Name: #{params[:role][:name]}"
puts red "Errors: #{JSON.parse(response.body.to_s)['errors']}"
has_encountred_issue = 1 # At least one of the migrations failed.
end
end
......@@ -78,6 +79,7 @@ namespace :migrations do
puts red "Unable to migrate User:"
puts yellow "UID: #{u.uid}"
puts yellow "Name: #{params[:user][:name]}"
puts red "Errors: #{JSON.parse(response.body.to_s)['errors']}"
has_encountred_issue = 1 # At least one of the migrations failed.
end
end
......@@ -142,6 +144,7 @@ namespace :migrations do
puts red "Unable to migrate Room:"
puts yellow "UID: #{r.uid}"
puts yellow "Name: #{r.name}"
puts red "Errors: #{JSON.parse(response.body.to_s)['errors']}"
has_encountred_issue = 1 # At least one of the migrations failed.
end
end
......@@ -192,6 +195,7 @@ namespace :migrations do
puts green "Successfully migrated Settings"
else
puts red "Unable to migrate Settings"
puts red "Errors: #{JSON.parse(response.body.to_s)['errors']}"
has_encountred_issue = 1 # At least one of the migrations failed.
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment