-
-
Notifications
You must be signed in to change notification settings - Fork 574
fix/jsonrpc id consistency #3777
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Updated the SSE server stream template to correctly handle multiple error responses by iterating through nested error structures. - Ensured that the generated code properly emits error handling cases for each defined error, improving robustness in SSE implementations. Tests: all unit tests pass; JSON-RPC integration tests pass.
…meter name collisions - Updated the analyze method in ServicesData to reserve the service package name, ensuring it does not conflict with parameter names in generated code. Tests: all unit tests pass.
…\n- SSE: emit protocol errors as SSE events; normalize error messages; no leaks (one-shot stream).\n- WS: fix request vs notification, generic error messages, empty-method handling.\n- HTTP: restore proper parse-error envelopes for invalid JSON.\n- Harness: support null/numeric IDs and explicit id presence for WS; honor JSONRPC field on SSE.\n- Scenarios: add WS/SSE protocol edge cases and mixed HTTP/JSON-RPC cases.\n- Templates: clean handler wiring (avoid recursion), correct SSE mount/init.\n\nAll JSON-RPC integration tests pass locally.
…ke executor and executor options private; Runner remains public.\n- update Runner to use private executor via factory/ctor.\n- minor formatting cleanups.\n\nAll integration tests pass.
…and emit GRPC() in DSL when set
…ndpoint generation; parse in MethodInfo and conditionally emit GRPC() in DSL; rename mixed scenario method to grpc_process
…c_ methods are present; auto-assign grpc port; detect readiness
…erver; only pass Svc to HTTP handler
…transports; make RawResponse.ID any; websocket client: treat missing id as nil and backfill via IDToString; integration tests: add numeric envelope id scenarios; idmap: payload/result use string id + string request_id; generator: only add id/request_id for idmap methods; fix echo impl for idmap; align scenarios to types
…llocate slices in server_data
… keep JSON-RPC endpoints; keep single-line handler calls
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Changes
RawResponse.IDis nowany.jsonrpc.IDToString.value,id(string), andrequest_id(string). Methods declare JSON-RPCID("request_id"). Non-idmap methods unchanged.Rationale
Backwards compatibility
Tests