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

Unable to update a metadata if the passed object doesn't have certain attributes #116

Closed
Guts opened this issue Sep 27, 2019 · 0 comments · Fixed by #117
Closed

Unable to update a metadata if the passed object doesn't have certain attributes #116

Guts opened this issue Sep 27, 2019 · 0 comments · Fixed by #117
Assignees
Labels
enhancement Amélioration de l'existant
Milestone

Comments

@Guts
Copy link
Contributor

Guts commented Sep 27, 2019

To reproduce:

from isogeo_pysdk import Isogeo, Metadata


[..authentication steps..]

# get the metadata to update
metadata_to_update = isogeo.metadata.get(metadata_id=the_uuid_of_the_metadata_to_update)

# simulate a newly empty object
newly_metadata = Metadata(_id=metadata_to_update._id)

# just edit the title
newly_metadata.title = "OMG I've been updated!"

# try to update
isogeo.metadata.update(nely_metadata)
>>> 500: Internal Server Error

Let's add a warning and document that.

@Guts Guts added the enhancement Amélioration de l'existant label Sep 27, 2019
@Guts Guts added this to the 3.2.3 milestone Sep 27, 2019
@Guts Guts self-assigned this Sep 27, 2019
Guts added a commit that referenced this issue Sep 27, 2019
Guts added a commit that referenced this issue Sep 30, 2019
Metadata - Check required attributes for update #116
@Guts Guts closed this as completed Sep 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Amélioration de l'existant
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant