ioBroker.repositories icon indicating copy to clipboard operation
ioBroker.repositories copied to clipboard

Please add adapter merakicmx to repository latest.

Open MiGoller opened this issue 4 years ago • 23 comments

Hey all,

please add my adapter ioBroker.merakicmx to the repository latest. There are no known issues to me and I still did not receive any negative feedback on https://forum.iobroker.net/topic/32352/test-adapter-merakicmx-v0-2-x-github-npm .

This is my first pull request to add one of my adapters to an ioBroker repository. Please let me know, if I will have to fulfill any further steps.

KR, Michael

MiGoller avatar Aug 19 '20 10:08 MiGoller

Automated adapter checker

ioBroker.merakicmx

Downloads NPM

:thumbsup: No errors found

  • [ ] :eyes: [W400] Cannot find "merakicmx" in latest repository

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

GermanBluefox avatar Aug 19 '20 20:08 GermanBluefox

@MiGoller

  • please do not subscribe unneeded to object changes (code does not do anything but triggers on changes) n: https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L31 https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L83-L90

  • same for on state change https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L32 https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L98-L106

  • on massage example from template can also be removed ? https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L33 https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L108-L123

  • better use timeout instead of interval to avoid multiple running processes (only start new time when previous action is completed) https://github.com/MiGoller/ioBroker.merakicmx/blob/master/main.js#L54

DutchmanNL avatar Sep 07 '20 19:09 DutchmanNL

@DutchmanNL Thank you for your feedback.

  • I've removed unneeded code and replaced intervals by a timeout implementation.
  • Travis CI builds are ok and the adapter works fine after modification in my testing environment.
  • I've updated version to 0.2.7

MiGoller avatar Sep 08 '20 05:09 MiGoller

Is there anything more I have to do?

MiGoller avatar Oct 29 '20 16:10 MiGoller

Hi, sorry for the delay. Here some review comments and required changes:

  • with adapter-core 2.4.0 as dep you need to require at least js-controller 2.0
  • would it make sense to store the secret encrypted? js.controller 3 can support here automatically
  • is this timout at https://github.com/MiGoller/ioBroker.merakicmx/blob/master/lib/merakiCmxDbConnector.js#L488 also cleared at unload?
  • tip: add on('error') handler to https://github.com/MiGoller/ioBroker.merakicmx/blob/master/lib/cmxreceiver.js ... else it can lead to exceptions and crashes

Thank you for checking and adjusting it

Apollon77 avatar Nov 25 '20 21:11 Apollon77

Hey @Apollon77 ,

thank you for your feedback. I've updated the dependencies and modified the code to clear the mentioned timeout under any circumstances. Can you give me a hint to find an example for the encrypted values mit js-controller 3.x?

But I'm struggling adding an error handler to cmreceiver.js. Right now I just can treat exceptions like bind address is in use only with a basic uncaughtException pattern. I'll have a further look at it the next days.

Thx,

KR, Michael

MiGoller avatar Nov 25 '20 23:11 MiGoller

an app.on('error', err => {...}) should work or?!

For auto encrypt you need:

  • config https://github.com/iobroker-community-adapters/ioBroker.tr-064/blob/master/io-package.json#L311-L316

And if you do not want to limit to js-controller 3 you also need "fallback" code like

  • https://github.com/iobroker-community-adapters/ioBroker.tr-064/blob/master/admin/index_m.html#L246-L248
  • https://github.com/iobroker-community-adapters/ioBroker.tr-064/blob/master/admin/index_m.html#L382-L384
  • https://github.com/iobroker-community-adapters/ioBroker.tr-064/blob/master/main.js#L111-L121

If you say "hey js-controller 3 is enough" then you just need nothing but the config

Apollon77 avatar Nov 25 '20 23:11 Apollon77

Hey @Apollon77 ,

Thanks a lot! I'll adopt the pattern to support js-controller 2.x as well. The mentioned code snippets will do the trick.

But adding the on('error', err => {...}) handler to the Express Application does not work; Express 4.x applications just support mount events (on('mount', err => {...})) (s. http://expressjs.com/en/4x/api.html#app.onmount). But the created Node.js http(s)-server does support error events. Errors like addresses or ports are already in use will not throw an uncaught exception and will not crash and restart the adapter anymore.

I'll let you know when I'll have finished the modifications. Thx again.

Kind Regards, MiGoller

MiGoller avatar Nov 27 '20 15:11 MiGoller

great to hear that the review feedback was valuable

Apollon77 avatar Nov 27 '20 23:11 Apollon77

@MiGoller Hey, any update?

Apollon77 avatar Feb 01 '21 06:02 Apollon77

Hey @Apollon77 . I wasn't operational for a while, but I'll start to continue the modifications. KR, MiGoller

MiGoller avatar Feb 03 '21 13:02 MiGoller

Just tell when done! Good luck

Apollon77 avatar Feb 16 '21 22:02 Apollon77

@MiGoller Can we support anyhow?

Apollon77 avatar Apr 08 '21 21:04 Apollon77

@Apollon77 Thank you very much. Just had a lot of work at the office after leaving the hospital. Just started to work at my ioBroker adapters to get them added to the ioBroker repositories. I'll let you know if you could support anyhow, ok?

MiGoller avatar Apr 08 '21 22:04 MiGoller

Awesome! If you need support or developer exchange join telegram groups or Discord ... some devs are always around there :-)

Apollon77 avatar Apr 08 '21 22:04 Apollon77

Link to discord Community https://discord.gg/HwUCwsH

DutchmanNL avatar Apr 10 '21 11:04 DutchmanNL

@MiGoller Any news?

Apollon77 avatar Jul 22 '21 20:07 Apollon77

@MiGoller Anything we can help with?

Apollon77 avatar Aug 27 '21 11:08 Apollon77

Hey @Apollon77 .

I'm glad for offering assistance. Hopefully you are a wizard who is able to generate me more time. ;-) I'm just to busy at my business work. Sorry for that.

I'll prepare the adapter as soon as possible.

KR, MiGoller

MiGoller avatar Aug 27 '21 11:08 MiGoller

Hm ... no, I also would like to find such a wizard ;-) I know that tooo good ... Also the "cloning machine" is still unfinished in my garage ;-)

Apollon77 avatar Aug 27 '21 11:08 Apollon77

Enjoy your weekend. I'll let you know when I'll need further assistance... and I will need it.

MiGoller avatar Aug 27 '21 14:08 MiGoller

@MiGoller - Hello MiGoller... do you need some help with the development?

ldittmar81 avatar Dec 22 '21 07:12 ldittmar81

@MiGoller How we should continue? Can we help somehow? Should we do a PR with relevant changes?

Apollon77 avatar Sep 16 '22 09:09 Apollon77

@MiGoller Happy new year, how we should proceed?

Apollon77 avatar Jan 13 '23 12:01 Apollon77

@Apollon77 , thank you for your support. Please close the request; I'll continue to enhance my Life360 adapter to get it added to the repo but not this adapter.

MiGoller avatar Jan 19 '23 19:01 MiGoller

@MiGoller I could also offer to provide a PR to adress the issues ... then it would be just testing that then ... because honestly ... it is not much what is left here ....

Apollon77 avatar Jan 20 '23 08:01 Apollon77

Hey @Apollon77 , thank you very much for your assistance. Please provide a PR and I'll do the tests. Thx

MiGoller avatar Jan 31 '23 22:01 MiGoller

I will try to find time soon, sorry for the delay

Apollon77 avatar May 21 '23 15:05 Apollon77

I might not find time soon ...

Apollon77 avatar Jul 26 '23 13:07 Apollon77

As there was no activity at this adapter since app 2 years and you stated that you do not plan to further develop this adapter (https://github.com/ioBroker/ioBroker.repositories/pull/886#issuecomment-1397498037) I will close here.

Please feel free to open a new PR at any time. I will do a ne review whenever requested by you.

THANKS for working with ioBroker and maintaining other adapter(s)

mcm1957 avatar Mar 03 '24 19:03 mcm1957