How to replace an official binding with a snapshot binding

I want to test the new chromecast binding from @holmes.j https://github.com/openhab/openhab2-addons/pull/2097

But I have a general question:
What is the recommended way to reaplace the official 2.1.0 binding with the snapshot version?

I am using text configuration.

So my first step is to delete chromecast from the addons.cfg.
Then I restart the openhab service to let openhab see the change and uninstall the official binding.
Next I copy the snapshot jar file to /usr/share/openhab2/addons and restart openhab again.
Is this right?

feature:list | grep chrome only shows that the 2.1.0 version is uninstalled.
How can I check if a custom version is installed?

openhab-binding-chromecast                  | 2.1.0            |          | Uninstalled | addons-2.1.0            | Chromecast Binding

The openhab.log is not clear either. :frowning:

2017-09-04 16:18:28.838 [INFO ] [core.karaf.internal.FeatureInstaller] - Uninstalled 'openhab-binding-chromecast'
2017-09-04 16:21:12.887 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.items'
2017-09-04 16:22:32.571 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.sitemap'
2017-09-04 16:22:57.404 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.things'
2017-09-04 16:29:51.227 [WARN ] [su.litvak.chromecast.api.v2.Channel ] - Error while reading
su.litvak.chromecast.api.v2.ChromeCastException: Remote socket closed
        at su.litvak.chromecast.api.v2.Channel.read(Channel.java:413)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel.access$200(Channel.java:50)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel$ReadThread.run(Channel.java:132)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
2017-09-04 16:29:51.244 [WARN ] [su.litvak.chromecast.api.v2.Channel ] -  <--  null payload in message
2017-09-04 16:30:18.431 [WARN ] [su.litvak.chromecast.api.v2.Channel ] - Error while reading
        at su.litvak.chromecast.api.v2.Channel.read(Channel.java:411)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel.access$200(Channel.java:50)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel$ReadThread.run(Channel.java:132)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
2017-09-04 16:30:18.436 [WARN ] [su.litvak.chromecast.api.v2.Channel ] -  <--  null payload in message
2017-09-04 16:30:18.438 [WARN ] [su.litvak.chromecast.api.v2.Channel ] - Error while closing channel
        at su.litvak.chromecast.api.v2.Channel.read(Channel.java:411)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel.access$200(Channel.java:50)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at su.litvak.chromecast.api.v2.Channel$ReadThread.run(Channel.java:132)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.handler.ChromecastHandler.updateState(ChromecastHandler.java:156)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.internal.ChromecastStatusUpdater.updateStatus(ChromecastStatusUpdater.java:242)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.internal.ChromecastStatusUpdater.updateStatus(ChromecastStatusUpdater.java:238)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.internal.ChromecastStatusUpdater.processStatusUpdate(ChromecastStatusUpdater.java:80)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.internal.ChromecastCommander.handleRefresh(ChromecastCommander.java:79)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.internal.ChromecastCommander.handleCommand(ChromecastCommander.java:46)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
        at org.openhab.binding.chromecast.handler.ChromecastHandler.handleCommand(ChromecastHandler.java:148)[228:org.openhab.binding.chromecast:2.2.0.201707030501]
2017-09-04 16:32:45.633 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.items'
2017-09-04 16:34:17.756 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.sitemap'
2017-09-04 16:34:27.572 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'chromecast.things'

Paper UI does not show the new binding either.

The new binding is working by the way!
But it is still unclear is this is the recommended way.

What would happen is I did not uninstall the 2.1.0 version?
Would openhab use the newest version?
Or is there a priority system to handle “installed via paper ui”, “via addons.cfg” and “via addons-folder”?
Is there no binding from addons folder was installed log message?

Hey, we once collected the steps needed in the FAQs here:

1 Like

Great!!
Thanks! :+1:

1 Like

Ah, btw: the FAQs are free to edit by everyone. If you feel anything is missing or could be described better - go for it!