tomasy / date-time-adapter

Date Time Adapter for Mozill IoT
Mozilla Public License 2.0
0 stars 4 forks source link

Getting error 400 during configuration plugin #26

Open mspbonn opened 3 years ago

mspbonn commented 3 years ago

I'm getting an error 400 during configuration plugin constantly.

How to solve this issue ?

mspbonn commented 3 years ago

As mentioned here, reboot does not help :-(

tomasy commented 3 years ago

When did it happen? After an upgrade? Do you have some logfile?

mspbonn commented 3 years ago

2020-12-06 12:09:21.175 INFO : Fetching add-on https://github.com/tomasy/date-time-adapter/releases/download/1.0.1/date-time-adapter-1.0.1.tgz as /tmp/uapSvn/date-time-adapter.tar.gz 2020-12-06 12:09:23.400 INFO : Expanding add-on /tmp/uapSvn/date-time-adapter.tar.gz 2020-12-06 12:09:27.703 INFO : Loading add-on: date-time-adapter 2020-12-06 12:09:54.354 INFO : date-time-adapter: Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple 2020-12-06 12:09:54.361 INFO : date-time-adapter: Collecting jsonschema (from -r requirements.txt (line 1)) 2020-12-06 12:09:57.387 INFO : date-time-adapter: Using cached https://files.pythonhosted.org/packages/69/11/a69e2a3c01b324a77d3a7c0570faa372e8448b666300c4117a516f8b1212/jsonschema-3.2.0.tar.gz 2020-12-06 12:09:59.737 INFO : date-time-adapter: Installing build dependencies: started 2020-12-06 12:10:59.757 INFO : date-time-adapter: Installing build dependencies: still running... 2020-12-06 12:11:05.824 ERROR : Failed to restart add-on date-time-adapter 2020-12-06 12:11:05.883 ERROR : TypeError: Cannot read property 'send' of undefined at Plugin.sendMsg (/home/pi/mozilla-iot/gateway/build/webpack:/src/plugin/plugin.js:580:1) at Plugin.unload (/home/pi/mozilla-iot/gateway/build/webpack:/src/plugin/plugin.js:737:1) at AddonManager.unloadAddon (/home/pi/mozilla-iot/gateway/build/webpack:/src/addon-manager.js:979:1) at ./src/controllers/addons_controller.js.AddonsController.put (/home/pi/mozilla-iot/gateway/build/webpack:/src/controllers/addons_controller.js:111:1)

mspbonn commented 3 years ago

I completely removed the addon (incl. settings from the sqlite database)

$ sqlite3 ./.webthings/config/db.sqlite3 "select * from settings where key like '%date-time-adapter%' "

and reinstalled the addon.

Same result:

2020-12-06 14:17:33.974 INFO : Fetching add-on https://github.com/tomasy/date-time-adapter/releases/download/1.0.1/date-time-adapter-1.0.1.tgz as /tmp/2dTvlv/date-time-adapter.tar.gz 2020-12-06 14:17:34.987 INFO : Expanding add-on /tmp/2dTvlv/date-time-adapter.tar.gz 2020-12-06 14:17:39.150 INFO : Loading add-on: date-time-adapter 2020-12-06 14:18:04.379 INFO : date-time-adapter: Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple 2020-12-06 14:18:04.388 INFO : date-time-adapter: Collecting jsonschema (from -r requirements.txt (line 1)) 2020-12-06 14:18:08.517 INFO : date-time-adapter: Using cached https://files.pythonhosted.org/packages/69/11/a69e2a3c01b324a77d3a7c0570faa372e8448b666300c4117a516f8b1212/jsonschema-3.2.0.tar.gz 2020-12-06 14:18:10.887 INFO : date-time-adapter: Installing build dependencies: started 2020-12-06 14:20:18.417 ERROR : Failed to restart add-on date-time-adapter 2020-12-06 14:20:18.453 ERROR : TypeError: Cannot read property 'send' of undefined at Plugin.sendMsg (/home/pi/mozilla-iot/gateway/build/webpack:/src/plugin/plugin.js:580:1) at Plugin.unload (/home/pi/mozilla-iot/gateway/build/webpack:/src/plugin/plugin.js:737:1) at AddonManager.unloadAddon (/home/pi/mozilla-iot/gateway/build/webpack:/src/addon-manager.js:979:1) at ./src/controllers/addons_controller.js.AddonsController.put (/home/pi/mozilla-iot/gateway/build/webpack:/src/controllers/addons_controller.js:111:1)

tomasy commented 3 years ago

I can see there was a new gateway released some days ago. Perhaps they have broken something. (This would not be the first problem after they have upgrade) There are some reported problems in discourse.mozilla.org. Check if you can rollback as the describe here and see if ti works. https://discourse.mozilla.org/t/problem-since-the-1-0-webthings-upgrade/71609

wfahle commented 3 years ago

I believe this issue was fixed when the adapter was updated to webthings 1.0.