-
Notifications
You must be signed in to change notification settings - Fork 436
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
v1.35.0 breaks any program trying to use a -v
flag
#1153
Comments
For what it's worth it appears that Google has no intention of fixing the underlying problem and libraries should just avoid depending on the glog package. |
@marcind sorry you're hitting this issue. I think it's reasonable to expect that upgrading That being said, it's a tricky situation. glog seems difficult to prune from our dependency graph without giving up on ristretto. We also can't use a On your end it seems like you should be able to use a FlagSet rather than relying on pkg-global state as a workaround? cc @gbbr who worked on the bits related to glog |
@felixge seems like the easiest might be to lobby for dgraph-io/ristretto#292 and/or dgraph-io/ristretto#293 as it appears dd-trace-go is not the only project affected by glog. Outside of that, have you considered not using ristretto? |
This can now be fixed by updating github.com/DataDog/datadog-agent/pkg/obfuscate version. As per this PR DataDog/datadog-agent#15005 they replaced the ristretto dependency with a maintained fork. Any chance to fix it? |
@radykal-com the problem should be fixed in main now, and will be released soon (ETA end of month, maybe early next month). Sorry this took so long and for the problems it has caused. |
The following simple program breaks when dd-trace-go is upgraded to v1.35.0
The output when executing
go run main.go
is something likeThis has been traced to the usage of the
github.com/golang/glog
package (which also uses the -v flag)Glog is imported via the following chain
The breaking change was introduced in #1069 (committed in f55a622).
Rolling back to the previous commit by executing
go get gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer@11c835cb0 && go mod tidy
makes the above-mentioned program work again.It is not my expectation that some transitive dependency of a transitive dependency would cause applications to break because some library thinks it knows better and decides to hijack a bunch of flags (including something as generic as
-v
).The text was updated successfully, but these errors were encountered: