Stream: python

Topic: โœ” 409 error from API - JSON Metadata Fields


view this post on Zulip Julien C (Oct 13 2023 at 14:17):

Hello,

Can someone tell me plz, if he has already seen this kind of error when "playing" with the Native API,
I try to update the metadata for a particular Dataset (put request in Python) and I get this response:

(409, {'status': 'ERROR', 'message': 'Terms of Use and Access are invalid. You must enable request access or add terms of access in datasets with restricted files.'})

Note: API version 5.10

I have edited the dataset in accordance for some "random" text for Terms of Use and it didn't work.
Request access is enable by default. I don't understand what I'm missing here.

Thanks in advance for your reply or help,
Regards

view this post on Zulip Philip Durbin ๐Ÿš€ (Oct 13 2023 at 14:19):

What if you do the equivalent operation in the web interface? Does it work?

view this post on Zulip Jan Range (Oct 16 2023 at 06:19):

Are you using pydataverse or plain requests in Python?

view this post on Zulip Julien C (Oct 16 2023 at 06:30):

OK solved, after running some tests, I have found that some datasets have restricted files in it. these files needs to be deactivated (=unrestricted temporary) in draft "mode" before upgrading dataset metadata for superior version.

view this post on Zulip Notification Bot (Oct 16 2023 at 12:23):

Julien C has marked this topic as resolved.

view this post on Zulip Notification Bot (Oct 16 2023 at 12:23):

Julien C has marked this topic as unresolved.

view this post on Zulip Notification Bot (Oct 16 2023 at 12:24):

Julien C has marked this topic as resolved.

view this post on Zulip Notification Bot (Oct 16 2023 at 12:24):

Julien C has marked this topic as unresolved.

view this post on Zulip Notification Bot (Oct 16 2023 at 12:24):

Julien C has marked this topic as resolved.


Last updated: Nov 01 2025 at 14:11 UTC