Repository navigation
Custom metadata broken in 0.12.0 #419
Copy link
Copy link
Closed
Labels
🚨This issue needs some love.This issue needs some love.api: storageIssues related to the Cloud Storage API.Issues related to the Cloud Storage API.triage meI really want to be triaged.I really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Description
Activity
Would you mind trying against master? I believe we realized this recently and it should be fixed for our next release.
Try the newest release! We just released v0.13.1 today.
- addedtype: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.api: storageIssues related to the Cloud Storage API.Issues related to the Cloud Storage API.
on Apr 6, 2015 This will work:
var options = { metadata: { contentType: 'text/plain', metadata: { customValue: 'MyValue' } } }; inStream.pipe(file.createWriteStream(options));
So, createWriteStream takes an options object. That object can hold a metadata object with file metadata, such as contentType. Inside of that, you can have another metadata object to hold custom values. It's a bit of a mind warp.
Sorry for my late response, I had this on my list but was unable to test it until now. I have now both upgraded to 1.13.2 and added the additional nesting in the options object, works as expected. Thanks for the fast reply and support.
- added🚨This issue needs some love.This issue needs some love.triage meI really want to be triaged.I really want to be triaged.
on Apr 6, 2020 - added a commit that references this issue
on Aug 22, 2022 - added a commit that references this issue
on Sep 15, 2022 - added a commit that references this issue
on Sep 27, 2022 19 remaining items
- added 4 commits that reference this issue
on Jan 27, 2026 - added a commit that references this issue
on Feb 17, 2026 - added a commit that references this issue
on Feb 25, 2026 - added a commit that references this issue
on Mar 5, 2026 - added a commit that references this issue
on Mar 5, 2026 - added a commit that references this issue
on Mar 12, 2026 - added a commit that references this issue
on Mar 18, 2026 - added 2 commits that reference this issue
on Mar 23, 2026 - added a commit that references this issue
on Mar 27, 2026 - added a commit that references this issue
on Mar 27, 2026 - added a commit that references this issue
on May 5, 2026
Metadata
Metadata
Assignees
Labels
🚨This issue needs some love.This issue needs some love.api: storageIssues related to the Cloud Storage API.Issues related to the Cloud Storage API.triage meI really want to be triaged.I really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Providing custom metadata via the
metadata.metadataproperty as documented at https://googlecloudplatform.github.io/gcloud-node/#/docs/v0.10.0/storage/file?method=setMetadata is not working for me with gcloud 0.12, but works fine with 0.11. Standard metadata works fine, too.Partial sample code: