-
Notifications
You must be signed in to change notification settings - Fork 837
fix: websocket runnable #6675
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
fix: websocket runnable #6675
Conversation
|
Claude finished @dieriba's task —— View job Code Review for PR: fix: websocket runnableTodo List:
Review SummaryThis PR refactors websocket runnable handling by consolidating duplicate logic and improving type safety. The changes primarily focus on removing code duplication and standardizing the handling of runnable arguments across different websocket trigger operations. Code Quality & Best Practices ✅Positive aspects:
Areas of concern: 1. Function Parameter Type Changes (
|
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.
Important
Looks good to me! 👍
Reviewed everything up to d3884c7 in 1 minute and 29 seconds. Click for details.
- Reviewed
120lines of code in3files - Skipped
0files when reviewing. - Skipped posting
3draft comments. View those below. - Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
1. backend/windmill-api/src/triggers/websocket/handler.rs:240
- Draft comment:
Mapping config.url_runnable_args with to_raw_value converts the Option<serde_json::Value> to the expected Option<&Box> for get_url_from_runnable_value. Confirm that input types are as intended. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%None
2. backend/windmill-api/src/triggers/websocket/listener.rs:156
- Draft comment:
The inline block now retrieves authed and converts the SqlxJson-wrapped url_runnable_args using .map(|r| &r.0) before calling get_url_from_runnable_value. Ensure that the unwrap on splitting the URL (using splitn and nth(1)) is safe given expected URL formats. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%None
3. backend/windmill-api/src/triggers/websocket/mod.rs:63
- Draft comment:
The updated value_to_args_hashmap now accepts Option<&Box> and uses serde_json::from_str(args.get()). This change ensures the raw JSON string is properly parsed. Verify that error handling and test cases cover any malformed JSON scenarios. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%None
Workflow ID: wflow_aqdYkLxzMRsb3FuR
You can customize by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.
Deploying windmill with
|
| Latest commit: |
d3884c7
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://08cde353.windmill.pages.dev |
| Branch Preview URL: | https://dieri-websocket-runnable.windmill.pages.dev |
Important
Refactor WebSocket URL handling by replacing
get_url_from_runnablewithget_url_from_runnable_valueand updating argument processing.get_url_from_runnablewithget_url_from_runnable_valueinlistener.rsandhandler.rs.get_url_from_runnable_valueto acceptargsasOption<&Box<RawValue>>.value_to_args_hashmapto handleOption<&Box<RawValue>>.to_raw_valueforurl_runnable_argsinhandler.rsandlistener.rs.raw_value_to_args_hashmapto convertargstoHashMap.get_url_from_runnablemethod fromlistener.rs.listener.rs.This description was created by
for d3884c7. You can customize this summary. It will automatically update as commits are pushed.