Skip to content

ProjectMember.save() does not work because 'ProjectMemberAllManager' object has no attribute 'update' #1825

@theoturner

Description

@theoturner

Description of the problem, including code/CLI snippet

ProjectMember.save() does not work because 'ProjectMemberAllManager' object has no attribute 'update'.

project = GitlabClient().projects.get('my_proj_name')
member = project.members.list()[0]
member.access_level = 30
member.save()

Expected Behavior

Member saves with new properties.
Actual Behavior

Traceback (most recent call last):
  File "gitlab_client.py", line 85, in update_project_permissions
    member.save()
  File "/Users/theoturner/Library/Python/3.8/lib/python/site-packages/gitlab/mixins.py", line 551, in save
    server_data = self.manager.update(obj_id, updated_data, **kwargs)
AttributeError: 'ProjectMemberAllManager' object has no attribute 'update'

N.B. type(member) is <class 'gitlab.v4.objects.members.ProjectMember'> so I haven't accidentally got a ProjectMemberAllManager.
Specifications

python-gitlab version: 3.0.0, can be replicated in 2.8 and above
API version you are using (v3/v4): v4

Note: John Villalovos accidentally edited this and now attempting to return to original state...

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    pFad - Phonifier reborn

    Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

    Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


    Alternative Proxies:

    Alternative Proxy

    pFad Proxy

    pFad v3 Proxy

    pFad v4 Proxy