mirror of
https://github.com/discourse/discourse.git
synced 2025-02-20 11:48:26 -06:00
Print out backtrace as well.
This commit is contained in:
parent
97395ebb66
commit
23415caecd
@ -11,11 +11,11 @@ reload_settings = lambda {
|
|||||||
unless String === SiteSetting.push_api_secret_key && SiteSetting.push_api_secret_key.length == 32
|
unless String === SiteSetting.push_api_secret_key && SiteSetting.push_api_secret_key.length == 32
|
||||||
SiteSetting.push_api_secret_key = SecureRandom.hex
|
SiteSetting.push_api_secret_key = SecureRandom.hex
|
||||||
end
|
end
|
||||||
|
|
||||||
rescue ActiveRecord::StatementInvalid
|
rescue ActiveRecord::StatementInvalid
|
||||||
# This will happen when migrating a new database
|
# This will happen when migrating a new database
|
||||||
rescue => e
|
rescue => e
|
||||||
STDERR.puts "URGENT: #{e} Failed to initialize site #{RailsMultisite::ConnectionManagement.current_db}"
|
STDERR.puts "URGENT: Failed to initialize site #{RailsMultisite::ConnectionManagement.current_db}:"\
|
||||||
|
"#{e.message}\n#{e.backtrace.join("\n")}"
|
||||||
# the show must go on, don't stop startup if multisite fails
|
# the show must go on, don't stop startup if multisite fails
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user