diff roundup/scripts/roundup_server.py @ 5608:5df309febe49

Path to support OPTIONS verb when using rest interface via roundup-server. Also make sure rest interface doesn't hang when processing OPTIONS, DELETE, PATCH which don't have a payload by creating a CONTENT_LENGTH of 0 if these verbs are used and CONTENT_LENGTH is missing.
author John Rouillard <rouilj@ieee.org>
date Fri, 08 Feb 2019 19:39:17 -0500
parents 3d80e7752783
children b3618882f906
line wrap: on
line diff
--- a/roundup/scripts/roundup_server.py	Wed Jan 30 18:11:02 2019 +0100
+++ b/roundup/scripts/roundup_server.py	Fri Feb 08 19:39:17 2019 -0500
@@ -255,7 +255,7 @@
                     print('EXCEPTION AT', ts)
                     traceback.print_exc()
 
-    do_GET = do_POST = do_HEAD = do_PUT = do_DELETE = do_PATCH = run_cgi
+    do_GET = do_POST = do_HEAD = do_PUT = do_DELETE = do_PATCH = do_OPTIONS = run_cgi
 
     def index(self):
         ''' Print up an index of the available trackers

Roundup Issue Tracker: http://roundup-tracker.org/