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

Add airquality to latest #4238

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

Conversation

raschy
Copy link
Contributor

@raschy raschy commented Oct 29, 2024

Please add my adapter ioBroker.airquality to latest.

This pull request was created by https://www.iobroker.dev c0726ff.

@github-actions github-actions bot added auto-checked This PR was automatically checked for obvious criterias must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review labels Oct 29, 2024
@mcm1957 mcm1957 added RE-REVIEW pending (by mcm1957) Changes requested by review have been applied, re-review could be done. new at LATEST labels Oct 29, 2024
@github-actions github-actions bot added *📬 a new comment has been added 5.11.2024 labels Oct 29, 2024
@ioBroker ioBroker deleted a comment from github-actions bot Oct 29, 2024
@mcm1957 mcm1957 removed the *📬 a new comment has been added label Oct 29, 2024
@simatec
Copy link
Contributor

simatec commented Oct 30, 2024

jsonConfig looks good. However, there is not really anything to configure. Is that the intention?

@github-actions github-actions bot added the *📬 a new comment has been added label Oct 30, 2024
@raschy
Copy link
Contributor Author

raschy commented Oct 30, 2024

Oh, yes. Under “Stations”, the user can/should enter the station(s) from which he wants to have measured values. That's all you need.

@raschy
Copy link
Contributor Author

raschy commented Oct 31, 2024

Issue 1 [E254] and [W040] corrected, solved in version 0.0.4

@mcm1957 mcm1957 removed the *📬 a new comment has been added label Nov 1, 2024
@github-actions github-actions bot deleted a comment from mcm1957 Nov 1, 2024
@mcm1957
Copy link
Collaborator

mcm1957 commented Nov 5, 2024

Sorry, but due to travel / absence I will not able to do the review before ioBroker Meeting Solingen next weekend.

@mcm1957 mcm1957 removed the must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review label Nov 5, 2024
@mcm1957
Copy link
Collaborator

mcm1957 commented Nov 26, 2024

@raschy

First of all - THANK YOU for the time and effort you spend to maintain this adapter.

I would like to give some feedback based on my personal oppinion. @Apollon77 might have additional suggestions or even a different oppinion to one or the other statement. Please feel free to contact him if you cannot follow my suggestions or want to discuss some special aspects.

  • package.json should require up to date js-controller and admin version

    New adapters should request js-controller 5 and admin 6 as minimum if there are no strong reason to support (and test) older releases. So please add / adapt at io-package.json:

          "dependencies": [
              {
                  "js-controller": ">=5.0.19"
              }
          ],
          "globalDependencies": [
              {
                  "admin": ">=6.17.14"
              }
          ]
    

    As this adapter uses jsonConfig it should require admin v6 at least. Earlier releases have too many missing updates.

  • directory 'logs'

    Does the directory "logs" really contain information needed for development or has it been commited by error?

  • consider making this adapter a scheduled adapter

    As this adapter executes every 15 minutes only please evaluate whether it shouldn't be converted to a scheduled adapter. It looks like an overhead to let a process wait most of the time.

  • object ids and name attribute of objects

    Object Ids must be named in english.

    The "name" attribute of all objects / states must be either a string in english or an i18n multilingual object with all supported languages. The only exception would be if the name attribute is directly delivered by the external system - which isn't he case here. I would suggest to use i18n

  • reevaluate state roles

    Only the values specified here (https://github.com/ioBroker/ioBroker.docs/blob/master/docs/en/dev/stateroles.md) may be used as state roles. Do not invent new names as this might disturb the functionalyity of other adapters or vis.

    In addition the roles MUST match the read/write functionality. As an example a role value.* requires that the state is a readable state. Input states (write only) should have roles like level.*. Please read the description carefully. States with role 'button' should (must) have attribute 'common.read=false' set. A button ( "Taster" in german only triggers when you press but else has no state), so it should also be not readable. This is also like HomeMatic does it. A switch has clear states true or false and so can be read.

    Please avoid using general roles (state, value) whenever a dedicated role exists.

image

Role 'number' does not exist ("Anzahl Messtypen")
Role "state" should only be used if no better role available. At least role value should be ok.
"Letzte Messung" should be role 'date' (eventually convert to make it parseable by new(date). See https://github.com/ioBroker/ioBroker.docs/blob/master/docs/en/dev/stateroles.md

Thanks for reading and evaluating this suggestions.
McM1957

Please add a comment when you have reviewed and fixed the suggestionsor at least commented the suggestions and you think the adapter is ready for a re-review!

reminder 10.12.2024

@mcm1957 mcm1957 added must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review and removed RE-REVIEW pending (by mcm1957) Changes requested by review have been applied, re-review could be done. labels Nov 26, 2024
@raschy
Copy link
Contributor Author

raschy commented Dec 12, 2024

Hopefully all bugs fixed and also migrated to ESLint 9.

@github-actions github-actions bot added the *📬 a new comment has been added label Dec 12, 2024
@mcm1957 mcm1957 added RE-REVIEW pending (by mcm1957) Changes requested by review have been applied, re-review could be done. and removed *📬 a new comment has been added must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review labels Dec 15, 2024
@github-actions github-actions bot added the must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review label Dec 15, 2024
Copy link

github-actions bot commented Dec 15, 2024

Automated adapter checker

ioBroker.airquality

Downloads Number of Installations (latest) - Test and Release
NPM

  • ❗ [E254] Version "0.1.0" listed at common.news at io-package.json does not exist at NPM. Please remove from news section.
  • 👀 [W401] Cannot find "airquality" in latest repository
  • 👀 [W951] .npmignore found but "files" is used at package.json. Please remove .npmignore.

Add comment "RE-CHECK!" to start check anew

@github-actions github-actions bot deleted a comment from mcm1957 Dec 15, 2024
@mcm1957
Copy link
Collaborator

mcm1957 commented Dec 15, 2024

RE-REVIEW - work in progress worksheet only - please ignore for now

  • package.json should require up to date js-controller and admin version

    New adapters should request js-controller 5 and admin 6 as minimum if there are no strong reason to support (and test) older releases. So please add / adapt at io-package.json:

          "dependencies": [
              {
                  "js-controller": ">=5.0.19"
              }
          ],
          "globalDependencies": [
              {
                  "admin": ">=6.17.14"
              }
          ]
    

    As this adapter uses jsonConfig it should require admin v6 at least. Earlier releases have too many missing updates.

  • directory 'logs'

    Does the directory "logs" really contain information needed for development or has it been commited by error?

  • consider making this adapter a scheduled adapter

    As this adapter executes every 15 minutes only please evaluate whether it shouldn't be converted to a scheduled adapter. It looks like an overhead to let a process wait most of the time.

  • object ids and name attribute of objects

    Object Ids must be named in english.

    The "name" attribute of all objects / states must be either a string in english or an i18n multilingual object with all supported languages. The only exception would be if the name attribute is directly delivered by the external system - which isn't he case here. I would suggest to use i18n

  • reevaluate state roles

    Only the values specified here (https://github.com/ioBroker/ioBroker.docs/blob/master/docs/en/dev/stateroles.md) may be used as state roles. Do not invent new names as this might disturb the functionalyity of other adapters or vis.

    In addition the roles MUST match the read/write functionality. As an example a role value.* requires that the state is a readable state. Input states (write only) should have roles like level.*. Please read the description carefully. States with role 'button' should (must) have attribute 'common.read=false' set. A button ( "Taster" in german only triggers when you press but else has no state), so it should also be not readable. This is also like HomeMatic does it. A switch has clear states true or false and so can be read.

    Please avoid using general roles (state, value) whenever a dedicated role exists.

image

Role 'number' does not exist ("Anzahl Messtypen")
Role "state" should only be used if no better role available. At least role value should be ok.
"Letzte Messung" should be role 'date' (eventually convert to make it parseable by new(date). See https://github.com/ioBroker/ioBroker.docs/blob/master/docs/en/dev/stateroles.md

  • linter setup

@github-actions github-actions bot added the *📬 a new comment has been added label Dec 15, 2024
@mcm1957 mcm1957 removed the *📬 a new comment has been added label Dec 15, 2024
@mcm1957
Copy link
Collaborator

mcm1957 commented Dec 15, 2024

@raschy
Thanks for fixing most issues. The following issue still exists

  • object ids and name attribute of objects

    Object Ids must be named in english.

    It looks like you are using the ids directly provided by UBA. So using english names could be not easy. Please check whether the site can provide english names too. I'll check with apollon if german ids could be accespt as an exception too.

    EDIT: Just check with @Apollon77 - its OK to keep german names as they are retrieved from api an target for users is germany anyway. No nee to be changed any more.

The following issues are new:

reminder 29.12.2024

@mcm1957 mcm1957 removed RE-REVIEW pending (by mcm1957) Changes requested by review have been applied, re-review could be done. 10.12.2024 labels Dec 15, 2024
@github-actions github-actions bot added the 29.12.2024 remind after 29.12.2024 label Dec 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
29.12.2024 remind after 29.12.2024 auto-checked This PR was automatically checked for obvious criterias must be fixed The Adapter request got review/automatic feedback that is required to be fixed before another review new at LATEST
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants