Plugin release questions

Hi there!
After my first plugin RotaryEncoder II was merged into Master a week ago. I wanted to try out if I can install it via the plugin store.
Some questions popped up during this:

  • I cannot see the plugin in the store yet. Is there anything else I have to do after the merge has been done?
  • I did another manual install to see, if the user can install the plugin manually already:
    • The plugin installs completely up to the 100% message, but after it issues the FINALIZING_INSTALLATION message twice, the command line hangs. On the GUI I get a dialog asking whether I want to activate the plugin, but after I say yes, the command line still hangs. Is this normal?
    • After I activate the plugin, I cannot access the settings yet. I first have to issue a volumio vrestart before I can configure the settings. Is this normal behavior or is there still a bug in my plugin?

Thanks and best regards,
Thomas

Hi Thomas,

Very interesting. Thank you.

  • yes - unfortunately this is normal
  • is it possible to do the vrestart at the end of the install routine ?

What is the difference to the existing plugin in terms of usability, features, stability ?
Unfortunately there is no readme or other documentation.

Will it also work with Volumio v3.x ?

Best Regards
Josef

Hi Josef,

probably good idea to just include the vrestart in the shell script.
The differences are described (together with a lot more info) in the documentation I created alongside.
Unfortunately, the pull-request for the documentation is still pending:
https://github.com/volumio/docs/pull/88
The docs can currently be found here:
https://github.com/volumio/docs/tree/334f7f2338b340c66ef2dc7ffb11dc43884e6c52/docs/06_Plugins_User_Manuals/01_rotaryencoder2

It was in the same folder in Github first, but I moved it to the docs repo - I’ll create a README.md pointing to the docs, once they have been merged.

Regarding v3, I did not try it yet, since my time is very limited and I did not have the time to install v3 on my hardware yet. Not sure if there are many changes in the way the plugin-system works?

Best regards,
Thomas

Hi Thomas,

Thank you, didn’t see it, it’s a very detailed documentation.
I will give it a try asap with the standard KT40 based china Rotary Encoder described in Saiyato’s docu and hardware debouncing.

This worked for me too, but your approach seems to be more native to me.

br
Josef

Hello
You just have to send a PR to master branch.
It must contains only sources, no node_moddules, no zip file.
No need to add vrestart in install. Type ctrl+c when you see finalising install.
It may not work on buster if node dependencies are compatible.
Please indicate supported arch (arm, x86).
Last point, I often meet PR with no functional plugin because not carefully tested. I’m not saying it is the case for yours, but please, author of plugin, check and recheck your work, from install, use and uninstall.
Thanks

Music Services Shield is published in the available downloads of Volumio UI for ARM, but does not appear for x86.

What do I need to do to add it to the published list for x86?

Is this a question for @balbuze ?

Thanks

You don’t have to do anything… It is just I have to rebuild a x86 machine to test and publish it. I try this weekend.

This is a lot of work for you! I hope it passes the tests. I have tested on two x86 machines here, so fingers crossed…

I hope all my merge requests are not creating too much work for you.

Hi balbuze,

thanks for the reply. I just tried to install the plugin again from my fork and that works instantaneously (including direct access to the settings). Maybe I messed something up in the PR, will generate new one after solving below issue:

I still have to do a volumio vrestart before it fully works. It seems, that socket.emit is only working after I do vrestart.
I tested this with a fresh very simple plugin that only connects a socket and emits messages every 10s. There it works. I assume there is a problem with an unresolved promise somewhere. Will try to find it and create a new PR when fixed… Sorry.

May take a while, this seems to be a hard one.

Hi Josef,

as you can read below, the plugin is not yet starting without a volumio vrestart, but feel free to try version 1.0.3, if you are ok to use the workaround.
Would be happy to hear if it works with the KT40, too.
Will try to fix the remaining issue asap.
br
Thomas

Hi Thomas,

Unfortunately i am quite busy currently.
I will try with the KT040 starting on July, 20th.

br
Josef

1 Like

Found the root-cause of the problem thanks to the hint from @balbuze, that a volumio vrestart is not required. I had accidentally put some variable initializations into onVolumioRestart instead of onStart.
I published version 1.0.4 with a fix and created a new PR.

Thanks to all and sorry for the inconvenience (I am still on a steep learning curve)

Ok thanks. I’ll have a look tomorrow :slightly_smiling_face:

Sorry, that it still does not work and I need to bother you again.

On my test-system it works like it should + I fortunately found another RPi with Volumio which I can use.
I was lucky and could reproduce the issue on the second RPi at first. But then, at a certain point during search it changed behavior and is also always working now.
Maybe somebody has an idea what to check - I am currently at a loss:

Both Systems:

  • RPi 3
  • Volumio 2.882

What I tried on the new RPi:

  • Downloaded several versions of the plugin from my Repo, unzipped, installed
  • Installation worked but after activation I could not access the Settings. Deinstalling did not work (same as described in the comment by @balbuze in my PR)
  • This behavior was stable
  • I tried several things but nothing helped, it was always failing
  • To check, what was happening internally, with nano I edited the config.json file in my tmp folder that I used for unzipping and changed the logging setting from false to true.
  • When I ran volumio plugin install and activated now, it started correctly and worked :exploding_head: No errors in the log, settings accessible, uninstall works
  • So I uninstalled from the web interface, downloaded a fresh zip and repeated the process - now it is always working, like on my other system, with all versions that failed before.

The only ideas I came up with were a wrong encoding of config.json, but that seems not to be the problem, because then it should fail again, when I repeat download and install again.

My problem now, is that I cannot reproduce the error on any of my RPi systems anymore :slightly_frowning_face:
Next I will try to setup a fresh system on another SD card. If anybody has any hints what to look at, I am happy for sugestions. Otherwise I am afraid that this is going to be a hard one…

Btw: This looks similar to the behavior I observed on the other RPi before, as described in Post 9