diff sat/plugins/plugin_comp_ap_gateway/http_server.py @ 3802:983df907d456

component AP gateway: set POST default response code to 202 (accepted)
author Goffi <goffi@goffi.org>
date Fri, 17 Jun 2022 14:15:23 +0200
parents b5c9021020df
children 36b167ddbfca
line wrap: on
line diff
--- a/sat/plugins/plugin_comp_ap_gateway/http_server.py	Fri Jun 17 14:15:23 2022 +0200
+++ b/sat/plugins/plugin_comp_ap_gateway/http_server.py	Fri Jun 17 14:15:23 2022 +0200
@@ -648,6 +648,8 @@
             request.finish()
             return
 
+        # default response code, may be changed, e.g. in case of exception
+        self.responseCode(request, http.ACCEPTED)
         try:
             return await self.APRequest(request, signing_actor)
         except Exception as e: