{"record":{"id":"b13024f4988494ca","repo":"Intervention/image","slug":"failed-to-apply-intervention-image-drivers-imagick-b13024","errorCode":null,"errorMessage":"Failed to apply Intervention\\Image\\Drivers\\Imagick\\Modifiers\\DrawPixelModifier, unable to build ImagickDraw object","messagePattern":"Failed to apply Intervention\\\\Image\\\\Drivers\\\\Imagick\\\\Modifiers\\\\DrawPixelModifier, unable to build ImagickDraw object","errorType":"exception","errorClass":"ModifierException","httpStatus":null,"severity":"error","filePath":"src/Drivers/Imagick/Modifiers/DrawPixelModifier.php","lineNumber":55,"sourceCode":"\n        return $image;\n    }\n\n    /**\n     * Build drawable pixel in given color.\n     *\n     * @throws ModifierException\n     */\n    private function pixel(ImagickPixel $color): ImagickDraw\n    {\n        try {\n            $pixel = new ImagickDraw();\n            $pixel->setFillColor($color);\n            $pixel->point($this->position->x(), $this->position->y());\n\n            return $pixel;\n        } catch (ImagickException | ImagickDrawException $e) {\n            throw new ModifierException(\n                'Failed to apply ' . self::class . ', unable to build ImagickDraw object',\n                previous: $e,\n            );\n        }\n    }\n}\n","sourceCodeStart":37,"sourceCodeEnd":62,"githubUrl":"https://github.com/Intervention/image/blob/5598b9e39751c34afc5cdee84abef77f92c26f68/src/Drivers/Imagick/Modifiers/DrawPixelModifier.php#L37-L62","documentation":"Error \"Failed to apply Intervention\\Image\\Drivers\\Imagick\\Modifiers\\DrawPixelModifier, unable to build ImagickDraw object\" thrown in Intervention/image.","triggerScenarios":"Thrown at src/Drivers/Imagick/Modifiers/DrawPixelModifier.php:55 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass a valid color for the pixel, e.g. a hex string like \"ff0000\" or a ColorInterface instance","Ensure the target Point coordinates are numeric","Confirm the imagick extension is loaded so \\ImagickDraw can be built"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5598b9e39751c34afc5cdee84abef77f92c26f68","analyzedAt":"2026-08-23T02:17:31.068Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}