google-cloud-go icon indicating copy to clipboard operation
google-cloud-go copied to clipboard

storage: HTTP client strips milliseconds from `Custom-Time`

Open maros7 opened this issue 2 years ago • 1 comments

Client

Storage

Environment

Any

Go Environment

Go 1.21

Code

Expected behavior

Milliseconds are supported as per https://cloud.google.com/storage/docs/metadata#custom-time and should not be stripped.

Actual behavior

Milliseconds are stripped due to using time.RFC3339.

https://github.com/googleapis/google-cloud-go/blob/fbe78a28e01043b059e86c6e960d092b299ac9a4/storage/storage.go#L1090-L1093

Screenshots

image

Additional context

gRPC client looks correct:

https://github.com/googleapis/google-cloud-go/blob/fbe78a28e01043b059e86c6e960d092b299ac9a4/storage/storage.go#L1135

https://github.com/googleapis/google-cloud-go/blob/fbe78a28e01043b059e86c6e960d092b299ac9a4/storage/storage.go#L1364-L1370

maros7 avatar Aug 16 '23 07:08 maros7

@tritone any progress on the fix?

maros7 avatar Jun 18 '24 06:06 maros7