@@ -490,21 +490,6 @@ def list_environments(self, search_text: Optional[str] = None):
490490 data .append (row )
491491 self .print (data , ignore_silent = True )
492492
493- # temporary fix till the new API is updated to return `sessionAttributes`
494- def _get_missing_session_attributes (self , app_id : str , profile_id : str ) -> dict :
495- if not self .listed_profiles :
496- self .listed_profiles = self .b .my_access .list_profiles ()
497- return next (
498- (
499- profile ['sessionAttributes' ]
500- for app in self .listed_profiles
501- if app ['appContainerId' ] == app_id
502- for profile in app .get ('profiles' , [])
503- if profile ['profileId' ] == profile_id
504- ),
505- [],
506- )
507-
508493 def _set_available_profiles (
509494 self ,
510495 from_cache_command = False ,
@@ -548,9 +533,7 @@ def _set_available_profiles(
548533 'profile_description' : profile ['papDescription' ],
549534 'profile_id' : profile_id ,
550535 'profile_name' : profile ['papName' ],
551- 'session_attributes' : profile .get (
552- 'sessionAttributes' , self ._get_missing_session_attributes (app_id , profile_id )
553- ),
536+ 'session_attributes' : profile ['sessionAttributes' ],
554537 }
555538 if row not in access_output :
556539 access_output .append (row )
0 commit comments