File tree Expand file tree Collapse file tree 3 files changed +8
-6
lines changed Expand file tree Collapse file tree 3 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -271,15 +271,17 @@ def memberships(self):
271271 """
272272 Retrieves full details of all group memberships, with users and nested groups.
273273 See: https://docs.atlassian.com/atlassian-crowd/5.3.1/REST/#usermanagement/1/group-getAllMemberships
274+ Retrieves full details of all group memberships, with users and nested groups.
275+ This resource is optimised for streaming XML responses, and does not support JSON responses.
274276 :return: All membership mapping dict
275277 """
276278 path = self ._crowd_api_url ("usermanagement" , "group/membership" )
277- headers = {' Accept' : ' application/xml' }
279+ headers = {" Accept" : " application/xml" }
278280 response = self .get (path , headers = headers , advanced_mode = True )
279281 root = etree .fromstring (response .content )
280282 memberships = {}
281- for member in root .xpath (' //membership' ):
282- group = member .get (' group' )
283- users = [user .get (' name' ) for user in member .xpath (' ./users/user' )]
283+ for member in root .xpath (" //membership" ):
284+ group = member .get (" group" )
285+ users = [user .get (" name" ) for user in member .xpath (" ./users/user" )]
284286 memberships [group ] = users
285287 return memberships
Original file line number Diff line number Diff line change @@ -14,5 +14,4 @@ python-magic
1414# On October 4, 2022 importlib-metadata released importlib-metadata 5.0.0 and in version 5.0.0
1515# They have Deprecated EntryPoints and that's why you are facing this error.
1616importlib-metadata <= 4.13.0
17- # Add this package to search string in json
18- jmespath
17+
Original file line number Diff line number Diff line change 44oauthlib
55requests_oauthlib
66requests-kerberos == 0.14.0
7+ # Add this package to search string in json
78jmespath
89beautifulsoup4
910lxml
You can’t perform that action at this time.
0 commit comments