{"record":{"id":"ef711355844d23cb","repo":"thephpleague/flysystem","slug":"unexpected-response-code-for-get","errorCode":null,"errorMessage":"Unexpected response code for GET: ","messagePattern":"Unexpected response code for GET: ","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"src/WebDAV/WebDAVAdapter.php","lineNumber":148,"sourceCode":"            $statusCode = $response['statusCode'];\n\n            if ($statusCode < 200 || $statusCode >= 300) {\n                throw new RuntimeException('Unexpected status code received: ' . $statusCode);\n            }\n        } catch (Throwable $exception) {\n            throw UnableToWriteFile::atLocation($path, $exception->getMessage(), $exception);\n        }\n    }\n\n    public function read(string $path): string\n    {\n        $location = $this->encodePath($this->prefixer->prefixPath($path));\n\n        try {\n            $response = $this->client->request('GET', $location);\n\n            if ($response['statusCode'] !== 200) {\n                throw new RuntimeException('Unexpected response code for GET: ' . $response['statusCode']);\n            }\n\n            return $response['body'];\n        } catch (Throwable $exception) {\n            throw UnableToReadFile::fromLocation($path, $exception->getMessage(), $exception);\n        }\n    }\n\n    public function readStream(string $path)\n    {\n        $location = $this->encodePath($this->prefixer->prefixPath($path));\n\n        try {\n            $url = $this->client->getAbsoluteUrl($location);\n            $request = new Request('GET', $url);\n            $response = $this->client->send($request);\n            $status = $response->getStatus();\n","sourceCodeStart":130,"sourceCodeEnd":166,"githubUrl":"https://github.com/thephpleague/flysystem/blob/b277b5dc3d56650b68904117124e79c851e12376/src/WebDAV/WebDAVAdapter.php#L130-L166","documentation":"Error \"Unexpected response code for GET: \" thrown in thephpleague/flysystem.","triggerScenarios":"Thrown at src/WebDAV/WebDAVAdapter.php:148 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b277b5dc3d56650b68904117124e79c851e12376","analyzedAt":"2026-08-17T04:28:35.741Z","schemaVersion":2},"datasetVersion":"2026-08-17T09:17:11.063Z"}