minimaws: python 2 is more fussy about generator function distinction (nw)

This commit is contained in:
Vas Crabb 2019-09-30 15:00:24 +10:00
parent 85376ad4df
commit fcbc60c183

View file

@ -438,9 +438,12 @@ class RomIdentHandler(QueryPageHandler):
return self.error_page(405) return self.error_page(405)
else: else:
self.start_response('200 OK', [('Content-type', 'text/html; chearset=utf-8'), ('Cache-Control', 'public, max-age=3600')]) self.start_response('200 OK', [('Content-type', 'text/html; chearset=utf-8'), ('Cache-Control', 'public, max-age=3600')])
yield htmltmpl.ROMIDENT_PAGE.substitute( return self.form_page()
app=self.js_escape(cgi.escape(self.application_uri, True)),
assets=self.js_escape(cgi.escape(urlparse.urljoin(self.application_uri, 'static'), True))).encode('utf-8') def form_page(self):
yield htmltmpl.ROMIDENT_PAGE.substitute(
app=self.js_escape(cgi.escape(self.application_uri, True)),
assets=self.js_escape(cgi.escape(urlparse.urljoin(self.application_uri, 'static'), True))).encode('utf-8')
class BiosRpcHandler(MachineRpcHandlerBase): class BiosRpcHandler(MachineRpcHandlerBase):