-
Notifications
You must be signed in to change notification settings - Fork 36
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
Init reporter #655
Init reporter #655
Conversation
@@ -1,6 +1,6 @@ | |||
module github.com/stateful/runme/v3 | |||
|
|||
go 1.22 | |||
go 1.22.0 |
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.
Needed to make it work in Linux
506f7e0
to
1cd2c68
Compare
1cd2c68
to
705116f
Compare
|
||
message TransformRequest { | ||
runme.parser.v1.Notebook notebook = 1; | ||
optional bool auto_save = 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.
Ln 11-30, we should group into one or multiple sub-messages. Protos are practically immutable and this laundry list of properties at the request message level is likely a long-term liability. Host
, Env
, VSC
? Honestly not even as important how it's grouped but it needs grouping.
I mean, I like ReporterExtension
, ReporterGit
, etc.
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.
Got it. I structured it this way so the "Transform" function can return the payload in the shape defined by the proto file, eliminating the need to do this on the client side. But I totally get your point 👍
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.
Right. Perhaps group them under a single message that's part of TransformRequest
.
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.
Addresed with a single "extension" message.
Can you please elaborate @peraltafederico why you chose to propose this "Transform" architecture? |
@sourishkrout Absolutely! The primary reason was to create a ready-to-use payload that can be sent to the Platform. Currently, it mainly filters out outputs that are not 'stdout,' but as we move the Platform GraphQL request to the Kernel, this behavior may change as needed. Any suggestions on this approach? |
In the PR's description, please. It's mainly to contextualize and memoize the intention of this PR more clearly. |
Converted to I'll be sure to make this mergeable so it won't dangle for too long. |
b1f8cc2
to
0d58e0e
Compare
740aab7
to
3c447b7
Compare
df44e26
to
c80d389
Compare
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.
Merging this as per the decision outlined in the description.
Quality Gate passedIssues Measures |
We've decided to forgo using the reporter to normalize the JSON payload and, instead, at a later stage, refactor it to report payloads to the remote backend. For now, disable the API; however, keep the types in place so it's not accidentally relied on.
Motivation
Normalize the payload before sending it to the Platform. The primary reason for this is to create a ready-to-use payload that can be sent to the Platform. Currently, it mainly filters out outputs that are not "stdout" but as we move the Platform GraphQL request to the Kernel, this behavior may change as needed.
(See also https://github.com/stateful/platform/pull/822 and stateful/vscode-runme#1558)