Skip to content

Commit 206f5e1

Browse files
committed
debug prints
1 parent 0708ff5 commit 206f5e1

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

python/hopsworks/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ def _get_cached_api_key_path():
342342
def _prompt_project(valid_connection, project, is_app):
343343
if project is None:
344344
if is_app:
345+
print("on app")
345346
# On Serverless we filter out projects owned by other users to make sure automatic login
346347
# without a prompt still happens when users add showcase projects created by other users
347348
saas_projects = valid_connection._project_api._get_owned_projects()

python/hopsworks_common/core/project_api.py

+4
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ def _get_owned_projects(self):
4545
# Raises
4646
`hopsworks.client.exceptions.RestAPIError`: If unable to get the project teams
4747
"""
48+
print("getting user owned projs")
4849
project_team_json = self._get_project_teams()
4950
projects = []
5051
if project_team_json:
@@ -53,8 +54,11 @@ def _get_owned_projects(self):
5354
# Until there is a better solution this code is used to get the current user_id to check project ownership
5455
current_user_uid = project_team_json[0]['user']['uid']
5556
for project_team in project_team_json:
57+
print(current_user_uid)
58+
print(project_team["project"]["owner"]["uid"])
5659
if project_team["project"]["owner"]["uid"] == current_user_uid:
5760
projects.append(self._get_project(project_team["project"]["name"]))
61+
print(projects)
5862
return projects
5963

6064

0 commit comments

Comments
 (0)