Open GaneshMSFT opened 1 year ago
Thank you for your feedback. This has been routed to the support team for assistance.
For Powershell, the limitation is from an old SDK limitation. You can work around it by set the blob meta data after uploading it as following script:
$meta = New-Object System.Collections.Generic.Dictionary"[String,String]"
$meta.Add("Description","")
$b = Get-AzStorageBlob -Context $Context -Container $ContainerName -Blob $BlobName
# or : $b = Set-AzStorageBlobContent -Context $Context -Container $ContainerName -Blob $BlobName -File $LocalFilePath -Metadata $Metadata
$b.BlobClient.SetMetadata($meta)
We will investigate how to fix it for longer term.
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @xgithubtriage.
Description
Set Blob Metadata API doesn't restrict users to define null as value for metadata. However, PS cmdlet Set-AzStorageBlobContent have validations in place so that users won't set null value. I see this behavior inconsistency in direct API calls vs PS. Can you please fix this?
Issue script & Debug output
Environment data
Module versions
Error output