Repository navigation
pkg/rpctype: remove unused net/rpc hub package - #8216
ramosian-glider wants to merge 6 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request replaces the custom TCP/RPC-based communication protocol between syz-manager and syz-hub with a modern HTTP/JSON-based API. It removes the legacy pkg/rpctype package and introduces a new pkg/hubapi package defining the client and request/response payloads. The syz-hub service now serves POST endpoints for connection and synchronization, and syz-manager and syz-hubtool have been updated to use the new HTTP client. A critical compilation error was identified in syz-hub/api.go where the non-existent errors.AsType function is used instead of the standard errors.As function.
| } | ||
|
|
||
| func writeBodyReadError(w http.ResponseWriter, msg string, err error) { | ||
| if _, ok := errors.AsType[*http.MaxBytesError](err); ok { |
There was a problem hiding this comment.
The function errors.AsType does not exist in the Go standard library errors package. This will cause a compilation error.
Please use the standard errors.As function instead.
| if _, ok := errors.AsType[*http.MaxBytesError](err); ok { | |
| var maxBytesErr *http.MaxBytesError | |
| if errors.As(err, &maxBytesErr) { |
Codecov Report❌ Patch coverage is Additional details and impacted files
🚀 New features to boost your workflow:
|
5e53c10 to
8b451f7
Compare
8b451f7 to
08f2071
Compare
Remove the unused
pkg/rpctypepackage (rpc.go,rpc_test.go,rpctype.go, -379 lines) now thatsyz-hub,syz-manager, andtools/syz-hubtoolusepkg/hubapiover HTTP.Fixes #8176