Looking at the schema in plugin.json you would expect this to work:
lightning-cli plugin subcommand=start plugin=/tmp/l1/reckless/my-plugin options='["my-option=my-value"]'
but this gives a "unknown parameter options" error. The c code actually doesn't look for an options argument but expects the options flattened like this:
lightning-cli plugin subcommand=start plugin=/tmp/l1/reckless/my-plugin my-option=my-value
While this is fine on the CLI, it does not work directly in our generated rust/protobuf code. It could be fixed in the rust code with a flatten annotation but there is no such thing for protobuf files. So i recommend changing the c code to actually look for an options argument. This would also better fit the json schema imo.
Looking at the schema in
plugin.jsonyou would expect this to work:lightning-cli plugin subcommand=start plugin=/tmp/l1/reckless/my-plugin options='["my-option=my-value"]'but this gives a "unknown parameter options" error. The c code actually doesn't look for an options argument but expects the options flattened like this:
lightning-cli plugin subcommand=start plugin=/tmp/l1/reckless/my-plugin my-option=my-valueWhile this is fine on the CLI, it does not work directly in our generated rust/protobuf code. It could be fixed in the rust code with a
flattenannotation but there is no such thing for protobuf files. So i recommend changing the c code to actually look for anoptionsargument. This would also better fit the json schema imo.