Closed stephenrichardson closed 5 months ago
Hi @stephenrichardson Thankyou for the interest in Fledge. Your python file looks good, assuming that you have saved the plugin under directory /usr/local/fledge/python/fledge/plugins/south/myplugin/"
and having python filename myplugin.py
. (Case sensitive myplugin)
myplugin/
└── myplugin.py
If you are still getting an errors with above structure, Would you mind to share /usr/local/fledge/python/fledge/plugins/south
directory contents, also which Fledge version are you using?
Hey @ashish-jabble I am using Fledge 2.4.0. My custom plugin was identical to my above example except it was named "sensor_works" (in the directory, the filename, the plugin_info() and the config -> default property). When I changed the name to "myplugin" or "s_worx" or "abc_works" or "sensorworks" or "sensor_workss" it was fine. Is there something in the name "sensor_works" that is an issue?
(in the directory, the filename, the plugin_info() and the config -> default property)
To discover a python based plugin the contract be like having same name in following areas a) directory b) python filename c) config->plugin->default property d) in plugin_info def - It can have with different name, so optional for the case
Is there something in the name "sensor_works" that is an issue?
Not really!
I have just tried your example with sensor_works name and it is working fine. I would recommend to restart the fledge and check again.
It works fine after restarting fledge. Good to know! Thanks.
As you can see I'm knew to fledge and just started working with it this week. Is this the best place to ask questions or are there some forums or other somewhere else?
or are there some forums or other somewhere else?
You can ask queries over slack https://lfedge.slack.com
and join channels like fledge-help
and fledge
.
I created a basic python plugin "myplugin.py" and saved it in "/usr/local/fledge/python/fledge/plugins/south/myplugin/". When I try to add it as a new south service I get the following log messages:
The http_south plugin loads fine. Am I missing something or is this a bug? This is on Ubuntu 18.04.
Plugin code: