{"action":"opened","issue":{"url":"https://api.github.com/repos/buildbot/buildbot/issues/4925","repository_url":"https://api.github.com/repos/buildbot/buildbot","labels_url":"https://api.github.com/repos/buildbot/buildbot/issues/4925/labels{/name}","comments_url":"https://api.github.com/repos/buildbot/buildbot/issues/4925/comments","events_url":"https://api.github.com/repos/buildbot/buildbot/issues/4925/events","html_url":"https://github.com/buildbot/buildbot/issues/4925","id":474286946,"node_id":"MDU6SXNzdWU0NzQyODY5NDY=","number":4925,"title":"Log not available with ShellCommand","user":{"login":"lgbav8r","id":53452657,"node_id":"MDQ6VXNlcjUzNDUyNjU3","avatar_url":"https://avatars0.githubusercontent.com/u/53452657?v=4","gravatar_id":"","url":"https://api.github.com/users/lgbav8r","html_url":"https://github.com/lgbav8r","followers_url":"https://api.github.com/users/lgbav8r/followers","following_url":"https://api.github.com/users/lgbav8r/following{/other_user}","gists_url":"https://api.github.com/users/lgbav8r/gists{/gist_id}","starred_url":"https://api.github.com/users/lgbav8r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lgbav8r/subscriptions","organizations_url":"https://api.github.com/users/lgbav8r/orgs","repos_url":"https://api.github.com/users/lgbav8r/repos","events_url":"https://api.github.com/users/lgbav8r/events{/privacy}","received_events_url":"https://api.github.com/users/lgbav8r/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2019-07-29T22:34:51Z","updated_at":"2019-07-29T22:34:51Z","closed_at":null,"author_association":"NONE","body":"I have been struggling on getting the stdio log for a custom buildstep that I had working on a very old version of buildbot (v 0.8).  I am now using 2.3.1 and only come up with an empty stdio log.  However, the buidlbot web status shows log infomation.  Basically calling log.getText() in the createSummary method returns an empty string.\r\n\r\nMy custom buildstep is:\r\n\r\nclass CoverageHTMLShellCommand(steps.ShellCommand):\r\n    def __init__(self,**kwargs):\r\n        self.command=kwargs['command']\r\n        self.kwargs=kwargs\r\n        super().__init__(**self.kwargs)\r\n\r\n    def createSummary(self, log):\r\n        buildnumber = self.getProperty('buildnumber')\r\n        builder = self.getProperty('buildername')\r\n        coverage_url='http://hydra/buildbot/{}/{}/{}'.format(projectname, builder, buildnumber)\r\n        percentage = 'N/A'\r\n\r\n        sio = StringIO(log.getText())\r\n        for line in sio.readlines():                                                                                                                                                                                                                     print(line)\r\n            if line.startswith('TOTAL'):\r\n                percentage = line.split()[-1]\r\n        print('percentage'+percentage)\r\n        self.addURL('coverage {}'.format(percentage), coverage_url)"}}
{"actor":{"display_login":"lgbav8r"}}