Skip to content

StorageClient.DownloadObject fails for gzipped data #1641

@Pagonis

Description

@Pagonis

I am downloading statistic reports from my google play developer console using StorageClient

storageClient.DownloadObject("pubsite_prod_rev_...", objectName, outputFile, null, progress); and I am getting the error message:

Incorrect hash: expected 'CXSlwQ==' (base64), was 'UOn3sg==' (base64)
at Google.Cloud.Storage.V1.StorageClientImpl.DownloadObjectImpl(String baseUri, Stream destination, DownloadObjectOptions options, IProgress1 progress) at Google.Cloud.Storage.V1.StorageClientImpl.DownloadObject(String bucket, String objectName, Stream destination, DownloadObjectOptions options, IProgress1 progress)
at GetGooglePlayData.Program.testAuth() in Program.cs:line 99

The downloaded file is exactly the same as downloaded in gsutil or browser.
I guess the issue is reconciliation of compressed and decompressed file. Google reports the file is 229B compressed and 978B decompressed.

The very same issue was already reported by another guy 6 months ago: https://stackoverflow.com/questions/44693652/downloading-from-google-cloud-storage-always-incorrect-hash

Metadata

Metadata

Assignees

Labels

api: storageIssues related to the Cloud Storage API.priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions