Skip to content

fix(labels): ensure label.save() works #937

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

Merged
merged 1 commit into from
Nov 14, 2019

Conversation

sathieu
Copy link
Contributor

@sathieu sathieu commented Nov 14, 2019

Otherwise, we get:

   File "gitlabracadabra/mixins/labels.py", line 67, in _process_labels
     current_label.save()
   File "gitlab/exceptions.py", line 267, in wrapped_f
     return f(*args, **kwargs)
   File "gitlab/v4/objects.py", line 896, in save
     self._update_attrs(server_data)
   File "gitlab/base.py", line 131, in _update_attrs
     self.__dict__["_attrs"].update(new_attrs)
 TypeError: 'NoneType' object is not iterable

Because server_data is None.

Otherwise, we get:
   File "gitlabracadabra/mixins/labels.py", line 67, in _process_labels
     current_label.save()
   File "gitlab/exceptions.py", line 267, in wrapped_f
     return f(*args, **kwargs)
   File "gitlab/v4/objects.py", line 896, in save
     self._update_attrs(server_data)
   File "gitlab/base.py", line 131, in _update_attrs
     self.__dict__["_attrs"].update(new_attrs)
 TypeError: 'NoneType' object is not iterable

Because server_data is None.
@max-wittig
Copy link
Member

Thanks for your MR!

@max-wittig max-wittig merged commit c937338 into python-gitlab:master Nov 14, 2019
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

Successfully merging this pull request may close these issues.

2 participants