Skip to content
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

Verification Request: @hb-haier/homebridge-plugin #724

Open
baranwang opened this issue Apr 29, 2024 · 12 comments
Open

Verification Request: @hb-haier/homebridge-plugin #724

baranwang opened this issue Apr 29, 2024 · 12 comments
Labels
awaiting-changes use after review has started - awaiting user to make changes to plugin request-verification

Comments

@baranwang
Copy link

Plugin Name

@hb-haier/homebridge-plugin

Link To GitHub Repo

https://github.com/baranwang/homebridge-plugin-haier

Plugin Icon (Optional)

No response

The plugin does not offer the same nor less functionality than that of any existing verified plugin.

🟢 Yes

The plugin successfully installs and does not start unless it is configured.

🟢 Yes

The plugin does not require the user to run Homebridge in a TTY or with non-standard startup parameters, even for initial configuration.

🟢 Yes

The plugin does not contain any analytics or calls that enable you to track the user.

🟢 Yes

If the plugin needs to write files to disk (cache, keys, etc.), it stores them inside the Homebridge storage directory.

🟢 Yes

The plugin does not throw unhandled exceptions, the plugin must catch and log its own errors.

🟢 Yes

More Information

No response

@baranwang baranwang added the pending the label given to a new verification/icon request label Apr 29, 2024
Copy link

🔴 The following pre-checks failed:

  • Package JSON: homepage missing or does not start with https://
  • Package JSON: 'postinstall' in scripts is not allowed
  • Package JSON: failed to import plugin as Cannot find module 'homebridge/lib/logger'
    Require stack:
  • /workspace/test-area/node_modules/@hb-haier/shared/dist/lib/api/index.js
  • /workspace/test-area/node_modules/@hb-haier/shared/dist/lib/index.js
  • /workspace/test-area/node_modules/@hb-haier/homebridge-plugin/dist/index.js
  • /workspace/index.ts
  • GitHub Repo: should contain releases
  • Config Schema JSON: does not contain a name schema property

🟢 The following pre-checks passed:

  • Installation: successfully installed
  • Package JSON: bugs.url exists and seems a valid URL
  • Package JSON: keywords exist and contain 'homebridge-plugin'
  • Package JSON: 'preinstall' in scripts is not present
  • Package JSON: 'install' in scripts is not present
  • Package JSON: engines.node property is compatible with Node 18
  • Package JSON: engines.node property is compatible with Node 20
  • Package JSON: engines.homebridge property is compatible with Homebridge 1.7.0
  • GitHub Repo: repository is public
  • GitHub Repo: repository is not archived
  • GitHub Repo: issues are enabled
  • NPM Package: has not been deprecated
  • Config Schema JSON: exists and is valid JSON
  • Config Schema JSON: contains a valid pluginAlias
  • Config Schema JSON: the pluginType is set to 'platform'
  • Dependencies: homebridge was not installed as a dependency
  • Dependencies: hap-nodejs was not installed as a dependency

⚠️ Please action these failures and then comment /check to run the checks again. Let us know if you need any help.

If updating your package.json and config.schema.json files, don't forget to publish a new version to NPM.

@github-actions github-actions bot added awaiting-changes use after review has started - awaiting user to make changes to plugin and removed pending the label given to a new verification/icon request labels Apr 29, 2024
@baranwang
Copy link
Author

/check

@github-actions github-actions bot added pending the label given to a new verification/icon request and removed awaiting-changes use after review has started - awaiting user to make changes to plugin labels Apr 29, 2024
Copy link

🔴 The following pre-checks failed:

  • Dependencies: homebridge was installed as a dependency
  • Dependencies: hap-nodejs was installed as a dependency

🟢 The following pre-checks passed:

  • Installation: successfully installed
  • Package JSON: homepage exists
  • Package JSON: bugs.url exists and seems a valid URL
  • Package JSON: keywords exist and contain 'homebridge-plugin'
  • Package JSON: 'preinstall' in scripts is not present
  • Package JSON: 'install' in scripts is not present
  • Package JSON: 'postinstall' in scripts is not present
  • Package JSON: engines.node property is compatible with Node 18
  • Package JSON: engines.node property is compatible with Node 20
  • Package JSON: engines.homebridge property is compatible with Homebridge 1.7.0
  • Package JSON: initializer function found
  • GitHub Repo: repository is public
  • GitHub Repo: repository is not archived
  • GitHub Repo: issues are enabled
  • GitHub Repo: contains releases
  • NPM Package: has not been deprecated
  • Config Schema JSON: exists and is valid JSON
  • Config Schema JSON: contains a valid pluginAlias
  • Config Schema JSON: the pluginType is set to 'platform'
  • Config Schema JSON: contains a name schema property

⚠️ Please action these failures and then comment /check to run the checks again. Let us know if you need any help.

If updating your package.json and config.schema.json files, don't forget to publish a new version to NPM.

@github-actions github-actions bot added awaiting-changes use after review has started - awaiting user to make changes to plugin and removed pending the label given to a new verification/icon request labels Apr 29, 2024
@baranwang
Copy link
Author

/check

@github-actions github-actions bot added pending the label given to a new verification/icon request and removed awaiting-changes use after review has started - awaiting user to make changes to plugin labels Apr 29, 2024
Copy link

🟢 The following pre-checks passed:

  • Installation: successfully installed
  • Package JSON: homepage exists
  • Package JSON: bugs.url exists and seems a valid URL
  • Package JSON: keywords exist and contain 'homebridge-plugin'
  • Package JSON: 'preinstall' in scripts is not present
  • Package JSON: 'install' in scripts is not present
  • Package JSON: 'postinstall' in scripts is not present
  • Package JSON: engines.node property is compatible with Node 18
  • Package JSON: engines.node property is compatible with Node 20
  • Package JSON: engines.homebridge property is compatible with Homebridge 1.7.0
  • Package JSON: initializer function found
  • GitHub Repo: repository is public
  • GitHub Repo: repository is not archived
  • GitHub Repo: issues are enabled
  • GitHub Repo: contains releases
  • NPM Package: has not been deprecated
  • Config Schema JSON: exists and is valid JSON
  • Config Schema JSON: contains a valid pluginAlias
  • Config Schema JSON: the pluginType is set to 'platform'
  • Config Schema JSON: contains a name schema property
  • Dependencies: homebridge was not installed as a dependency
  • Dependencies: hap-nodejs was not installed as a dependency

🎉 All pre-checks passed successfully, nice work! Your plugin and/or icon will now be manually reviewed by the Homebridge team.

@bwp91
Copy link
Contributor

bwp91 commented May 26, 2024

Hi @baranwang

What are the cases when this script would need to be run? I mean which cases would these folders not already be present?

https://github.com/baranwang/homebridge-plugin-haier/blob/main/packages/plugin/scripts/generate-ui.js

@bwp91 bwp91 added currently-reviewing use for starting a review - adds a comment with the verification list with empty checkboxes and removed pending the label given to a new verification/icon request labels May 26, 2024
Copy link

github-actions bot commented May 26, 2024

  • General
    • The plugin must be of type dynamic platform.
    • The plugin must not offer the same nor less functionality than that of any existing verified plugin.
  • Repo
    • The plugin must be published to NPM and the source code available on a GitHub repository, with issues enabled.
    • A GitHub release should be created for every new version of your plugin, with release notes.
  • Environment
    • The plugin must run on all supported LTS versions of Node.js, at the time of writing this is Node v18 and v20.
    • The plugin must successfully install and not start unless it is configured.
    • The plugin must not execute post-install scripts that modify the users' system in any way.
    • The plugin must not require the user to run Homebridge in a TTY or with non-standard startup parameters, even for initial configuration.
  • Codebase
    • The plugin must implement the Homebridge Plugin Settings GUI.
    • The plugin must not contain any analytics or calls that enable you to track the user.
    • If the plugin needs to write files to disk (cache, keys, etc.), it must store them inside the Homebridge storage directory.
    • The plugin must not throw unhandled exceptions, the plugin must catch and log its own errors.

@bwp91
Copy link
Contributor

bwp91 commented May 26, 2024

Also when I type in a password in the UI screen I get an error notification and then I see in the HB logs

[26/05/2024, 12:28:11] [Homebridge UI] [@hb-haier/homebridge-plugin] Incoming Request: /family
[26/05/2024, 12:28:11] [Homebridge UI] [@hb-haier/homebridge-plugin] Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/.hb-haier/token'
    at Object.mkdirSync (node:fs:1372:26)
    at get tokenPath [as tokenPath] (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:122:25)
    at HaierApi.getTokenInfo (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:227:43)
    at new HaierApi (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:72:10)
    at UiServer.<anonymous> (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:36:23)
    at Generator.next (<anonymous>)
    at /usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:19:61
    at new Promise (<anonymous>)
    at __async (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:3:10)
    at UiServer.getFamilyList (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:35:12) {
  errno: -13,
  code: 'EACCES',
  syscall: 'mkdir',
  path: '/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/.hb-haier/token'
}
[26/05/2024, 12:28:27] [Homebridge UI] [@hb-haier/homebridge-plugin] Incoming Request: /family
[26/05/2024, 12:28:27] [Homebridge UI] [@hb-haier/homebridge-plugin] Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/.hb-haier/token'
    at Object.mkdirSync (node:fs:1372:26)
    at get tokenPath [as tokenPath] (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:122:25)
    at HaierApi.getTokenInfo (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:227:43)
    at new HaierApi (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/api/index.js:72:10)
    at UiServer.<anonymous> (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:36:23)
    at Generator.next (<anonymous>)
    at /usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:19:61
    at new Promise (<anonymous>)
    at __async (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:3:10)
    at UiServer.getFamilyList (/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/ui-server/dist/index.js:35:12) {
  errno: -13,
  code: 'EACCES',
  syscall: 'mkdir',
  path: '/usr/local/lib/node_modules/@hb-haier/homebridge-plugin/node_modules/@hb-haier/shared/dist/lib/.hb-haier/token'
}
[26/05/2024, 12:28:34] [Homebridge UI] Changes to config.json saved.

Happy that this doesn't cause the process to crash, but is there something wrong here?

@bwp91 bwp91 added awaiting-user-reply use after review has started - awaiting user to reply to a comment and removed currently-reviewing use for starting a review - adds a comment with the verification list with empty checkboxes labels May 26, 2024
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale used for stale issues label Jun 25, 2024
@bwp91 bwp91 removed the stale used for stale issues label Jun 25, 2024
@baranwang
Copy link
Author

Sorry @bwp91 for replying so late.

Regarding the execution problem of the generate-ui.js script, it is because the @hb-haier/homebridge-plugin package does not contain custom UI code, mainly because if I build it in the package, there will be no We received feedback from users that the custom UI failed to load and the configuration page could not appear. So I put the custom UI compilation logic in two other packages as dependencies, and soft-linked them to the package after installation.

The second error problem you mentioned seems to me that there is no way to obtain user.storagePath and triggers the hidden logic to create a cache directory in the package. But, there is an error due to lack of permissions, so is it true that some users cannot obtain this user.storagePath directory?

@bwp91 bwp91 added pending the label given to a new verification/icon request and removed awaiting-user-reply use after review has started - awaiting user to reply to a comment labels Jul 13, 2024
@bwp91
Copy link
Contributor

bwp91 commented Sep 22, 2024

/check

Copy link

🔴 The following checks failed:

  • Package JSON: 'postinstall' in scripts is not allowed

🟢 The following checks passed:

  • Installation: successfully installed
  • Package JSON: homepage exists
  • Package JSON: bugs.url exists and seems a valid URL
  • Package JSON: keywords exist and contain 'homebridge-plugin'
  • Package JSON: 'preinstall' in scripts is not present
  • Package JSON: 'install' in scripts is not present
  • Package JSON: engines.node property is compatible with Node 18
  • Package JSON: engines.node property is compatible with Node 20
  • Package JSON: engines.homebridge property is compatible with Homebridge 1.8.4
  • Package JSON: initializer function found
  • GitHub Repo: repository is public
  • GitHub Repo: repository is not archived
  • GitHub Repo: issues are enabled
  • GitHub Repo: contains releases
  • NPM Package: has not been deprecated
  • Config Schema JSON: exists and is valid JSON
  • Config Schema JSON: contains a valid pluginAlias
  • Config Schema JSON: the pluginType is set to 'platform'
  • Config Schema JSON: contains a name schema property
  • Dependencies: homebridge was not installed as a dependency
  • Dependencies: hap-nodejs was not installed as a dependency

⚠️ Please action these failures and then comment /check to run the checks again. Let us know if you need any help.

If updating your package.json and config.schema.json files, don't forget to publish a new version to NPM.

@github-actions github-actions bot added the awaiting-changes use after review has started - awaiting user to make changes to plugin label Sep 22, 2024
@github-actions github-actions bot removed the pending the label given to a new verification/icon request label Sep 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-changes use after review has started - awaiting user to make changes to plugin request-verification
Projects
None yet
Development

No branches or pull requests

2 participants