mirror of https://github.com/databricks/cli.git
pass test
This commit is contained in:
parent
da0cf951b9
commit
88015876ad
|
@ -1 +1 @@
|
|||
{"method":"POST","path":"/telemetry-ext","body":{"uploadTime":1738560432192,"items":[],"protoLogs":["{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"cli_test_event\":{\"name\":\"VALUE1\"}}}}","{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"cli_test_event\":{\"name\":\"VALUE2\"}}}}"]}}
|
||||
{"method":"POST","path":"/telemetry-ext","body":{"uploadTime":"UNIX_TIME_MILLIS","items":[],"protoLogs":["{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"cli_test_event\":{\"name\":\"VALUE1\"}}}}","{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"cli_test_event\":{\"name\":\"VALUE2\"}}}}"]}}
|
||||
|
|
|
@ -7,3 +7,8 @@ Response.Body = '''
|
|||
"numProtoSuccess": 2
|
||||
}
|
||||
'''
|
||||
|
||||
|
||||
[[Repls]]
|
||||
Old = '17\d{11}'
|
||||
New = '"UNIX_TIME_MILLIS"'
|
||||
|
|
|
@ -2,7 +2,7 @@ package telemetry
|
|||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"errors"
|
||||
)
|
||||
|
||||
// Private type to store the telemetry logger in the context
|
||||
|
@ -18,7 +18,7 @@ func WithNewLogger(ctx context.Context) context.Context {
|
|||
func fromContext(ctx context.Context) *logger {
|
||||
v := ctx.Value(telemetryLoggerKey)
|
||||
if v == nil {
|
||||
panic(fmt.Errorf("telemetry logger not found in the context"))
|
||||
panic(errors.New("telemetry logger not found in the context"))
|
||||
}
|
||||
|
||||
return v.(*logger)
|
||||
|
|
Loading…
Reference in New Issue