You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've got a test that runs the plugin server in a goroutine and fetches the reattach config from the server using ServeTestConfig.ReattachConfigCh, passing it to the client. The problem is that the server and client are versioned, so the client config has a map of VersionedPlugins while Plugins is empty. When the client is created using the reattach config, Client.Start exits early by calling c.reattach(), skipping the part where the plugin version is determined and leaving ClientConfig.Plugins set to nil. The client is therefore not initialized correctly and can't be used.
I found that executing the version handshake when reattaching solves my problem. Before opening a PR I wanted to ask if this is the proper way to address this issue, or if I'm missing something else.
I've got a test that runs the plugin server in a goroutine and fetches the reattach config from the server using
ServeTestConfig.ReattachConfigCh
, passing it to the client. The problem is that the server and client are versioned, so the client config has a map ofVersionedPlugins
whilePlugins
is empty. When the client is created using the reattach config,Client.Start
exits early by callingc.reattach()
, skipping the part where the plugin version is determined and leavingClientConfig.Plugins
set tonil
. The client is therefore not initialized correctly and can't be used.I found that executing the version handshake when reattaching solves my problem. Before opening a PR I wanted to ask if this is the proper way to address this issue, or if I'm missing something else.
lovromazgon@a3d2cd0
The text was updated successfully, but these errors were encountered: