Skip to content

Mark and save plugin as disabled if platform fails to initialize #3800

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: latest
Choose a base branch
from

Conversation

justjam2013
Copy link
Contributor

♻️ Current situation

Currently, if a plugin throws an error when initializing, it takes down the entire Homebridge and forces it into a restart loop.

💡 Proposed solution

If a plugin throws an error when initializing, log an error, mark the plugin as disabled, and update the Homebridge config.

⚙️ Release Notes

The user will have to manually re-enable the plugin when they believe that the issue has been resolved, for example an invalid plugin config.

➕ Additional Information

N/A

Testing

N/A

Reviewer Nudging

N/A

@coveralls
Copy link

Pull Request Test Coverage Report for Build 13950433333

Details

  • 2 of 19 (10.53%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall first build on disable-failed-plugin at 28.34%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/server.ts 2 19 10.53%
Totals Coverage Status
Change from base Build 13258186304: 28.3%
Covered Lines: 433
Relevant Lines: 1389

💛 - Coveralls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants