Skip to content

Commit bcf46ec

Browse files
gctuckerJenySadadia
authored andcommitted
src: update all services to use new API.User class
Use the new API.User bindings class in all services for user-related operations. Signed-off-by: Guillaume Tucker <gtucker@gtucker.io>
1 parent 01a5861 commit bcf46ec

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/timeout.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def __init__(self, configs, args, name):
2727
state.value for state in self._api.node.states
2828
if state != state.DONE
2929
]
30-
self._user = self._api.whoami()
30+
self._user = self._api.user.whoami()
3131
self._username = self._user['username']
3232

3333
def _setup(self, args):

src/trigger.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class Trigger(Service):
2828
def __init__(self, configs, args):
2929
super().__init__(configs, args, 'trigger')
3030
self._build_configs = configs['build_configs']
31-
self._current_user = self._api.whoami()
31+
self._current_user = self._api.user.whoami()
3232

3333
def _log_revision(self, message, build_config, head_commit):
3434
self.log.info(f"{message:32s} {build_config.name:32s} {head_commit}")

0 commit comments

Comments
 (0)