Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3490)

Unified Diff: chrome/common/extensions/docs/server2/preview.py

Issue 10827138: Extension docs server: fix errors in preview.py. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: . Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/docs/server2/preview.py
diff --git a/chrome/common/extensions/docs/server2/preview.py b/chrome/common/extensions/docs/server2/preview.py
index 5c644bfb069f049f614baf1e29af100af8d2ca69..1cd4e43281fe89bc2d76c8583b15186d512b91c0 100755
--- a/chrome/common/extensions/docs/server2/preview.py
+++ b/chrome/common/extensions/docs/server2/preview.py
@@ -55,19 +55,19 @@ if __name__ == '__main__':
parser = optparse.OptionParser(
description='Runs a server to preview the extension documentation.',
usage='usage: %prog [option]...')
- parser.add_option('-p', '--port', default=8000,
+ parser.add_option('-p', '--port', default="8000",
help='port to run the server on')
(opts, argv) = parser.parse_args()
- try:
- print('Starting previewserver on port %d' % opts.port)
- print('The extension documentation can be found at:')
- print('')
- print(' http://localhost:%d' % opts.port)
- print('')
+ print('Starting previewserver on port %s' % opts.port)
+ print('The extension documentation can be found at:')
+ print('')
+ print(' http://localhost:%s' % opts.port)
+ print('')
- server = HTTPServer(('', int(opts.port)), RequestHandler)
+ server = HTTPServer(('', int(opts.port)), RequestHandler)
+ try:
server.serve_forever()
except KeyboardInterrupt:
pass
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698