{"record":{"id":"1b814c0352561ef3","repo":"oraios/serena","slug":"request-to-url-timed-out-e","errorCode":null,"errorMessage":"Request to {url} timed out: {e}","messagePattern":"Request to (.+?) timed out: (.+?)","errorType":"exception","errorClass":"ConnectionError","httpStatus":null,"severity":"error","filePath":"src/serena/jetbrains/jetbrains_plugin_client.py","lineNumber":343,"sourceCode":"                raise ValueError(f\"Unsupported HTTP method: {method}\")\n\n            response.raise_for_status()\n\n            # Try to parse JSON response\n            try:\n                response_json = response.json()\n                if pythonify:\n                    return self._pythonify_response(response_json)\n                else:\n                    return response_json\n            except json.JSONDecodeError:\n                # If response is not JSON, return raw text\n                return {\"response\": response.text}\n\n        except requests.exceptions.ConnectionError as e:\n            raise ConnectionError(f\"Failed to connect to Serena service at {url}: {e}\")\n        except requests.exceptions.Timeout as e:\n            raise ConnectionError(f\"Request to {url} timed out: {e}\")\n        except requests.exceptions.HTTPError as e:\n            if response is not None:\n                # check for recoverable error (i.e. errors where the problem can be resolved by the caller or\n                # other errors where the error text shall simply be passed on to the LLM).\n                # The plugin returns 400 for such errors (typically illegal arguments, e.g. non-unique name path)\n                # but only since version 2023.2.6\n                if self.is_version_at_least(2023, 2, 6):\n                    is_recoverable_error = response.status_code == 400\n                else:\n                    is_recoverable_error = True  # assume recoverable for older versions (mix of errors)\n                if is_recoverable_error:\n                    raise APIError(response)\n                raise PluginServerError(f\"API request failed with status {response.status_code}: {response.text}\")\n            raise PluginServerError(f\"API request failed with HTTP error: {e}\")\n        except requests.exceptions.RequestException as e:\n            raise SerenaClientError(f\"Request failed: {e}\")\n\n    @staticmethod","sourceCodeStart":325,"sourceCodeEnd":361,"githubUrl":"https://github.com/oraios/serena/blob/7fcbca7e62555ec2287ddb2f083caee805848ea6/src/serena/jetbrains/jetbrains_plugin_client.py#L325-L361","documentation":"_make_request maps requests.exceptions.Timeout to ConnectionError('Request to {url} timed out'). The Serena plugin service accepted the connection but did not respond within the configured timeout — typically the IDE is busy (indexing, long operation) or the requested analysis is heavy.","triggerScenarios":"find_symbol/move/get_supertypes/etc. issued while the IDE is indexing, a modal dialog blocks the IDE's request handling, or the operation itself (e.g. wide symbol search) exceeds the client timeout.","commonSituations":"Large projects still indexing after open; IDE paused on breakpoint or unfocused power-save mode; slow machine; timeout too small for large codebase operations.","solutions":["Retry the request once the IDE finishes indexing (watch the status bar)","Increase the plugin client request timeout if configurable","Reduce operation scope (narrower symbol name/path depth)","Restart the IDE if it's unresponsive to plugin requests"],"exampleFix":null,"handlingStrategy":"retry","validationCode":"import time\n# avoid calling while the IDE is indexing: poll a cheap endpoint first\ndef wait_until_ready(client, attempts: int = 10):\n    for _ in range(attempts):\n        try:\n            client.get_symbols_overview(relative_path=\".\")\n            return\n        except ConnectionError:\n            time.sleep(2)\n    raise TimeoutError(\"Serena plugin service not responding\")","typeGuard":null,"tryCatchPattern":"try:\n    syms = client.find_symbol(name_path=\"Foo\")\nexcept ConnectionError as e:\n    if \"timed out\" in str(e):\n        time.sleep(2)\n        syms = client.find_symbol(name_path=\"Foo\")  # single retry\n    else:\n        raise","preventionTips":["Wait for IDE indexing to finish before issuing symbol queries","Increase the client timeout for large projects","Narrow queries (specific symbol paths, depth) to reduce server work","Keep the IDE responsive (disable power-save mode, avoid modal blockers)"],"tags":["network","jetbrains","timeout","http"],"backgroundTag":"request-timeout","analyzedSha":"7fcbca7e62555ec2287ddb2f083caee805848ea6","analyzedAt":"2026-08-29T00:04:09.619Z","schemaVersion":2},"datasetVersion":"2026-08-29T02:17:18.158Z"}