Client list users method have attribute wrongly spell
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 48/100
Research direction
Start at the list_users() API client entry point and inspect the returned user dictionaries for the spelling of the active WebSocket session attribute. Done means the returned key uses activeWebSocketSessions consistently and the shown list_active_users() usage can identify active users without relying on the misspelled key.
Written by the indexing model from the issue text.
Description
See I wanted to know all the users which are currently active.
Problem with the current code is, list_users() returns list of dictionary. And each dictionary has attribute activeWebSocketSesssions, ideally this should be activeWebSocketSessions.
Note - I wanted to make that change using the pull request, but I did not find this attribute in the current codebase, may be because you guys did not revel it, may be not. Aways this is my finding, that will help make this product a bit better.
def list_active_users(self):
"""
Get all the active users who currently login to the DSS
This method takes nothing and returns name of the users who are actively working now
Returns:
string: calculate all currently active users
"""
user_list = []
dss_users = self.client.list_users()
for user in dss_users:
if user["activeWebSocketSesssions"] != 0:
user_list.append(user["displayName"])
return user_list
- Dominant language
- Python
- Stars
- 44
- Forks
- 29
- Avg merge
- 3h 34m
- Merged PRs (30d)
- 2
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from dataiku/dataiku-api-client-python
-
Difficulty 3/5 1-2 days Newbie friendliness 55/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
-
Difficulty 4/5 3-5 days Newbie friendliness 30/100
dataiku/dataiku-api-client-python#335 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
All issues in dataiku/dataiku-api-client-python
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
-
🐛 Bug 🔔 Pending processing
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
jumpserver/jumpserver#17584 ·