{"record":{"id":"42aea60f1817b39f","repo":"PHPOffice/PhpSpreadsheet","slug":"chart-has-no-plotarea","errorCode":null,"errorMessage":"Chart has no PlotArea","messagePattern":"Chart has no PlotArea","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/PhpSpreadsheet/Chart/Chart.php","lineNumber":304,"sourceCode":"    {\n        $this->yAxisLabel = $label;\n\n        return $this;\n    }\n\n    public function getPlotArea(): ?PlotArea\n    {\n        return $this->plotArea;\n    }\n\n    public function getPlotAreaOrThrow(): PlotArea\n    {\n        $plotArea = $this->getPlotArea();\n        if ($plotArea !== null) {\n            return $plotArea;\n        }\n\n        throw new Exception('Chart has no PlotArea');\n    }\n\n    /**\n     * Set Plot Area.\n     */\n    public function setPlotArea(PlotArea $plotArea): self\n    {\n        $this->plotArea = $plotArea;\n\n        return $this;\n    }\n\n    /**\n     * Get Plot Visible Only.\n     */\n    public function getPlotVisibleOnly(): bool\n    {\n        return $this->plotVisibleOnly;","sourceCodeStart":286,"sourceCodeEnd":322,"githubUrl":"https://github.com/PHPOffice/PhpSpreadsheet/blob/65b080eef4d9fd11a5796135ab145883e5c3d6a6/src/PhpSpreadsheet/Chart/Chart.php#L286-L322","documentation":"Error \"Chart has no PlotArea\" thrown in PHPOffice/PhpSpreadsheet.","triggerScenarios":"Thrown at src/PhpSpreadsheet/Chart/Chart.php:304 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":"65b080eef4d9fd11a5796135ab145883e5c3d6a6","analyzedAt":"2026-08-17T05:40:41.646Z","schemaVersion":2},"datasetVersion":"2026-08-17T09:17:11.063Z"}