-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add the plugin runner process #7
Conversation
protobufs/generate_protobufs.sh
Outdated
@@ -0,0 +1,4 @@ | |||
#! /bin/sh | |||
|
|||
# poetry run python -m grpc_tools.protoc -I=protobufs/ --python_out=plugin_runner/ --pyi_out=plugin_runner/ --grpc_python_out=plugin_runner/ protobufs/**/*.proto |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I run the poetry run ...
version, I get a complaint about python versions. I thought that was like the whole point of poetry?
To run this script, you'll have to poetry shell
first.
protobufs/messages/effects.proto
Outdated
string payload = 2; | ||
//Oneof effect_payload { | ||
// ... | ||
//} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Keeping it simple for now. We will gradually introduce more specific payload attributes based on the effect type.
protobufs/messages/events.proto
Outdated
// Oneof target = 2 { | ||
// | ||
// } | ||
string target = 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Keeping it simple for now, will gradually add more specific target types based on the event type.
protobufs/messages/events.proto
Outdated
enum EventType { | ||
UNKNOWN = 0; | ||
|
||
// Workflow kit-inspired events |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a thought - do we want to look at all the events canvas-core too? i think it has more than the workflow kit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah definitely. Is there a list somewhere?
1685a1e
to
c56f5fb
Compare
Satisfies Jira tickets:
This PR adds a python program that implements the gRPC service
PluginRunner
and itshandle_event
method.This also adds some initial protobufs that represent the Event, EventResponse, and Effect types.
This also adds an enum of events. I added a bunch to the enum up front based on the workflow_sdk
CHANGE_TYPE
s, and made them more descriptive about create vs update vs other special cases. Just because the event is listed in that enum doesn't mean home-app will ever emit it. This just claims the event name for potential future use.