You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Yuri Shkuro (Jira)" <ji...@apache.org> on 2021/05/24 20:31:00 UTC
[jira] [Created] (THRIFT-5420) Go library should not depend on
"testing" in the main package
Yuri Shkuro created THRIFT-5420:
-----------------------------------
Summary: Go library should not depend on "testing" in the main package
Key: THRIFT-5420
URL: https://issues.apache.org/jira/browse/THRIFT-5420
Project: Thrift
Issue Type: Improvement
Components: Go - Library
Affects Versions: 0.14.1, 0.14.0
Reporter: Yuri Shkuro
From [https://github.com/jaegertracing/jaeger-client-go/issues/585:]
*Describe the bug*
Importing {{jaeger-client-go}} adds a dependency on the standard library "testing" package. This is undesirable because production Go programs should not depend on the testing package. In addition to unnecessary bloat, "testing" adds a bunch of command line flags.
The dependency is coming from [https://github.com/apache/thrift/blob/66d897667c451ef6560d89b979b7001c57a3eda6/lib/go/thrift/logger.go#L58]
*Recommendation*
Move TestLogger to a sub-module like "testutils". Or remove completely since it's a trivial implementation that can be easily reproduced. Or replace testing.TB argument with a locally defined interface that exposes Errorf function.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)