Skip to content

Commit

Permalink
Merge pull request #252 from lzaoral/client-watch-log-hub
Browse files Browse the repository at this point in the history
client: accept `--hub` option in `watch-log` command
  • Loading branch information
rohanpm authored Mar 14, 2024
2 parents 6e56481 + 68a4b29 commit 022ba22
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kobo/client/commands/cmd_watch_log.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ def run(self, *args, **kwargs):
# HACK: We're presuming, that urls were not touched and that base_url
# is also url of web ui. As we suppose that also task.urls were not
# altered it should work.
url = self.conf['HUB_URL'].replace('/xmlrpc', '') + '/task/%d/log-json/%s?offset=%d'
hub = kwargs.pop('hub', None) or self.conf['HUB_URL']
url = hub.replace('/xmlrpc', '') + '/task/%d/log-json/%s?offset=%d'
offset = 0
assert url.startswith(("http:", "https:"))
while True:
Expand Down

0 comments on commit 022ba22

Please sign in to comment.