{"record":{"id":"2ae86356f08a9de0","repo":"XX-net/XX-Net","slug":"request-http-localhost-8084-quit-e-r","errorCode":null,"errorMessage":"request http://localhost:8084/quit/ e:%r","messagePattern":"request http://localhost:8084/quit/ e:%r","errorType":"console","errorClass":null,"httpStatus":null,"severity":"info","filePath":"code/default/launcher/web_control.py","lineNumber":317,"sourceCode":"            elif url_path == '/installed_app':\n                self.req_get_installed_app()\n            elif url_path == '/init_module':\n                self.req_init_module_handler()\n            elif url_path == '/quit':\n                content = b'System: %s Exited successfully.' % utils.to_bytes(sys_platform.platform)\n                try:\n                    self.send_response('text/html', content)\n                    self.wfile.flush()\n                except:\n                    pass\n\n                xlog.info(\"start quit\")\n                if sys_platform.platform in [\"android\", \"ios\"]:\n                    try:\n                        xlog.info(\"request http://localhost:8084/quit/\")\n                        simple_http_client.request(\"GET\", \"http://localhost:8084/quit/\", timeout=1)\n                    except Exception as e:\n                        xlog.warn(\"request http://localhost:8084/quit/ e:%r\", e)\n                        pass\n\n                sys_platform.on_quit()\n            elif url_path == \"/debug\":\n                self.req_debug_handler()\n            elif url_path == \"/log_files\":\n                self.req_log_files()\n            elif url_path == \"/mem_info\":\n                self.req_mem_info_handler()\n            elif url_path == \"/gc\":\n                self.req_gc_handler()\n            elif url_path == '/restart':\n                self.send_response('text/html', '{\"status\":\"success\"}')\n                update_from_github.restart_xxnet()\n            else:\n                self.send_not_found()\n                xlog.info('%s \"%s %s HTTP/1.1\" 404 -', self.address_string(), self.command, self.path)\n","sourceCodeStart":299,"sourceCodeEnd":335,"githubUrl":"https://github.com/XX-net/XX-Net/blob/cfa5bc17b67676e467f37ec50766127e0ab5f0aa/code/default/launcher/web_control.py#L299-L335","documentation":"During /quit handling on android/ios, the launcher fires a best-effort GET to http://localhost:8084/quit/ to stop a companion process; failure is logged and swallowed (pass).","triggerScenarios":"Quit on a mobile platform when nothing listens on 8084 or it doesn't answer within the 1s timeout.","commonSituations":"The companion service already exited, was never started, or the port changed. Harmless — shutdown continues via sys_platform.on_quit().","solutions":["Ignore: quit proceeds regardless.","If the companion should be running, check its logs/port 8084 binding.","Align the hardcoded port with the companion's configured port."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":"try:\n    simple_http_client.request('GET','http://localhost:8084/quit/', timeout=1)\nexcept Exception:\n    pass  # best-effort; shutdown continues","preventionTips":["Treat this log as benign on mobile quits.","Verify companion service port if it should be running."],"tags":["shutdown","mobile","localhost","timeout"],"backgroundTag":"quit-request-failed","analyzedSha":"cfa5bc17b67676e467f37ec50766127e0ab5f0aa","analyzedAt":"2026-08-27T19:28:28.225Z","schemaVersion":2},"datasetVersion":"2026-08-28T00:17:15.603Z"}