Skip to content

Commit

Permalink
Merge branch 'main' into issue-21-parameter-name
Browse files Browse the repository at this point in the history
  • Loading branch information
Teddy-1000 committed Feb 20, 2024
2 parents d98d690 + 53ac5d6 commit 075223a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,11 @@ func getTSMdata(colVals map[string]interface{}) (*datastore.TSMetadata, error) {
switch field.Kind() {
case reflect.String:
val0, ok := val.(string)
if !ok {
return nil, fmt.Errorf(
"value not string: %v (type: %T; goName: %s, pbName: %s",
val, val, goName, pbName)
if ok { // NOTE: !ok in this case would typically mean a nil value resulting from a
// NULL in the corresponding database column
field.SetString(val0)
}
field.SetString(val0)

default:
return nil, fmt.Errorf(
"unsupported type: %v (val: %v; type: %T; goName: %s; pbName: %s)",
Expand Down
2 changes: 1 addition & 1 deletion protobuf/datastore.proto
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ message TSMetadata {
string level = 24;
string period = 25;
string function = 26;
string parameter_name = 27;
string parameter_name = 27 [json_name = "parameter_name"];
// --- END string metadata -----------------
}

Expand Down

1 comment on commit 075223a

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API Unit Test Coverage Report
FileStmtsMissCoverMissing
\_\_init\_\_.py00100% 
datastore_pb2.py584621%24–69
datastore_pb2_grpc.py432347%37–52, 85–87, 92–94, 99–101, 106–108, 112–136, 174, 191, 208, 225
dependencies.py493627%16–53, 63–71, 79–86
grpc_getter.py13838%12–16, 20–24
locustfile.py15150%1–31
main.py22386%27, 37, 47
metadata_endpoints.py20480%17, 34–67, 71
formatters
   \_\_init\_\_.py70100% 
   covjson.py462741%26–76, 82–91
routers
   \_\_init\_\_.py00100% 
   edr.py714339%37–60, 77–90, 105–120, 135–161
   records.py00100% 
TOTAL34420540% 

API Unit Test Coverage Summary

Tests Skipped Failures Errors Time
1 0 💤 0 ❌ 1 🔥 1.604s ⏱️

Please sign in to comment.