Skip to content

Conversation

@JohnVillalovos
Copy link
Collaborator

If unable to access the database provide a helpful error message.

Now the error message will say:
Unable to connect to the database. Ask the website administrator to
verify that the database has been created/initialized. They should
also verify that the config/config.php database configuration is
correct.

Previously it said:
Unknown Error

Copilot AI review requested due to automatic review settings February 10, 2026 23:24
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a more specific, actionable error message when the app fails to connect/select the database, instead of always showing “Unknown Error”.

Changes:

  • Map DB connection/select failures to a new ErrorMessages::DATABASE_CONNECTION error ID in the global web exception handler.
  • Add the new error message ID/resource key mapping.
  • Add the English (en_us) localized string for the new DB connection error.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
lib/Common/Logging/ExceptionHandler.php Detects DB connection/select exceptions and routes to a specific error message ID.
lib/Common/ErrorMessages.php Introduces DATABASE_CONNECTION and maps it to DatabaseConnectionError.
lang/en_us.php Adds the user-facing DatabaseConnectionError string.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

If unable to access the database provide a helpful error message.

Now the error message will say:
  Unable to connect to the database.

  Ask the website administrator to verify that the database has been
  created/initialized.

  They should also verify that the config/config.php database
  configuration is correct.

Previously it said:
  Unknown Error

Added machine translations of the error messages for German, Spanish,
and Japanese.
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@JohnVillalovos JohnVillalovos merged commit 4f48ec2 into develop Feb 11, 2026
17 checks passed
@JohnVillalovos JohnVillalovos deleted the jlvillal/no_db branch February 11, 2026 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant