Skip to content
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

[Bug] Unwanted stderr output when running tctl commands #313

Open
hferentschik opened this issue Oct 13, 2022 · 4 comments
Open

[Bug] Unwanted stderr output when running tctl commands #313

hferentschik opened this issue Oct 13, 2022 · 4 comments
Labels
bug Something isn't working

Comments

@hferentschik
Copy link

hferentschik commented Oct 13, 2022

What are you really trying to do?

Run any tctl commands

Describe the bug

When running any tctl command with the 1.16.3 version, there is additional stderr output appearing from hashicorp/go-plugin. For example:

$ tctx exec -c dev -- tctl wf describe --wid foo --rid 8858b620-89f5-4104-b6cc-8fc40e77de42                                                                                                                                
2022-10-13T15:26:13.585+0200 [WARN]  tctl: plugin configured with a nil SecureConfig
2022-10-13T15:26:13.608+0200 [WARN]  tctl: plugin configured with a nil SecureConfig
{
...
}
2022-10-13T15:26:14.698+0200 [INFO]  tctl: plugin process exited: path=/opt/homebrew/bin/tctl-data-converter pid=72439

Minimal Reproduction

Run any tctl while using a plugin as well, e.g. a DataConverter plugin.

Environment/Versions

$ tctl --version
tctl version 1.16.3

Additional context

This is most likely related to the commit 16ee92c which bumps hashicorp/go-plugin. When I build tctl from source, I can see the described behaviour. If I downgrade the go-plugin version, it is gone.

@hferentschik hferentschik added the bug Something isn't working label Oct 13, 2022
@hferentschik hferentschik changed the title [Bug] [Bug] Unwanted stderr output when running tctl commands Oct 13, 2022
@hferentschik
Copy link
Author

See also hashicorp/go-plugin#207.

@hferentschik
Copy link
Author

hferentschik commented Oct 14, 2022

So in my case, the rub seems to be here:

func newPluginClient(kind string, name string) (interface{}, error) {

Here the plugin client for the DataConverter is created without specifying a SecureConfig. Setting the logger level to error or off makes the warnings disappear.
The alternative would be to provide a SecureConfig, but tbh I am not sure how this would work. The SecureConfig expects a hash of the binary the client is going to execute. I am not sure how the process would like to pass/configure this hash, and in the case of custom converters, I doubt that there are hashes available at all times.

@feedmeapples
Copy link
Contributor

is this an option to switch to codec server instead of using plugins?

in the new cli we've removed plugins in favor of codec server

@hferentschik
Copy link
Author

is this an option to switch to codec server instead of using plugins?

Potentially. Question is whether one wants to do something about this issue for now in tctl. I guess tctl will continue to be in use for some time forward.

in the new cli we've removed plugins in favor of codec server

I see. Good to know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants