Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update_object_meta replaces previously added headers #323

Open
tomplus opened this issue Dec 29, 2022 · 0 comments
Open

update_object_meta replaces previously added headers #323

tomplus opened this issue Dec 29, 2022 · 0 comments

Comments

@tomplus
Copy link

tomplus commented Dec 29, 2022

Hello.

As I can see in the example in the documentation: https://www.alibabacloud.com/help/en/object-storage-service/latest/manage-object-metadata-1

after run this example

bucket.update_object_meta(key, {'x-oss-meta-author': 'O. Henry'})
bucket.update_object_meta(key, {'x-oss-meta-price': '100 dollar'})

I expect to have two headers x-oss-meta-author, x-oss-meta-price but only last one exists.

It looks like it's caused by this directive:

headers[OSS_METADATA_DIRECTIVE] = 'REPLACE'

introduced by 7769f1e

Can this directive be removed or exposed as an optional argument? I'm ready to create a PR if you wish.

Thanks.

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

No branches or pull requests

1 participant