Skip to content

Conversation

@abe-winter
Copy link
Member

@abe-winter abe-winter commented Nov 25, 2025

What changed

  • log hex instead of stringified bytes

Why

Stringified bytes causes the proto library to print 'unable to construct structpb.Struct from map' which distracted me while debugging something else

Sample output

Before:

2025-11-25T21:36:55.156Z WARN viam-agent agent/version_control.go:263 mismatched checksum, redownloading {"expected":"\ufffdt\ufffd~\ufffd\u0004\ufffd\ufffd\ufffd*\ufffdx0\ufffd<\ufffd\ufffd\ufffd4\ufffd\ufffdz`t+\ufffdؐ0jL\ufffd","actual":"","url":"https://storage.googleapis.com/download/storage/v1/b/packages.viam.com/o/apps%2Fviam-agent%2Fviam-agent-v0.23.0-x86_64?generation=1762893861750149&alt=media"}

unable to construct structpb.Struct from map map[Integer:0 Interface: Key:expected String:�t�~����*�x0�<���4��zt+�ؐ0jL� Type:15]: proto: invalid UTF-8 in string: "\xb6t\x94~\xf4\x04\xb4\x80\xf1*\xcfx0\xdc<\x89\xa7\x844\xbb\xf7zt+\x9dؐ0jL\xef"2025-11-25T21:36:55.156Z INFOviam-agent utils/utils.go:160 Starting download of https://storage.googleapis.com/download/storage/v1/b/packages.viam.com/o/apps%2Fviam-agent%2Fviam-agent-v0.23.0-x86_64?generation=1762893861750149&alt=media

After:

2025-11-25T22:04:20.571Z WARN viam-agent agent/version_control.go:264 mismatched checksum, redownloading {"expected":"b674947ef404b480f12acf7830dc3c89a78434bbf77a60742b9dd890306a4cef","actual":"","url":"https://storage.googleapis.com/download/storage/v1/b/packages.viam.com/o/apps%2Fviam-agent%2Fviam-agent-v0.23.0-x86_64?generation=1762893861750149&alt=media"}

2025-11-25T22:04:20.572Z INFO viam-agent utils/utils.go:160 Starting download of https://storage.googleapis.com/download/storage/v1/b/packages.viam.com/o/apps%2Fviam-agent%2Fviam-agent-v0.23.0-x86_64?generation=1762893861750149&alt=media

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants