{"record":{"id":"ddb70d845928f8f9","repo":"Seldaek/monolog","slug":"the-flowdockhandler-must-be-configured-via-setfor","errorCode":null,"errorMessage":"The FlowdockHandler must be configured (via setFormatter) with an instance of Monolog\\Formatter\\FlowdockFormatter to function correctly","messagePattern":"The FlowdockHandler must be configured \\(via setFormatter\\) with an instance of Monolog\\\\Formatter\\\\FlowdockFormatter to function correctly","errorType":"exception","errorClass":"InvalidArgumentException","httpStatus":null,"severity":"error","filePath":"src/Monolog/Handler/FlowdockHandler.php","lineNumber":83,"sourceCode":"\n    /**\n     * @inheritDoc\n     */\n    public function setFormatter(FormatterInterface $formatter): HandlerInterface\n    {\n        if (!$formatter instanceof FlowdockFormatter) {\n            throw new \\InvalidArgumentException('The FlowdockHandler requires an instance of Monolog\\Formatter\\FlowdockFormatter to function correctly');\n        }\n\n        return parent::setFormatter($formatter);\n    }\n\n    /**\n     * Gets the default formatter.\n     */\n    protected function getDefaultFormatter(): FormatterInterface\n    {\n        throw new \\InvalidArgumentException('The FlowdockHandler must be configured (via setFormatter) with an instance of Monolog\\Formatter\\FlowdockFormatter to function correctly');\n    }\n\n    /**\n     * @inheritDoc\n     */\n    protected function write(LogRecord $record): void\n    {\n        parent::write($record);\n\n        $this->closeSocket();\n    }\n\n    /**\n     * @inheritDoc\n     */\n    protected function generateDataStream(LogRecord $record): string\n    {\n        $content = $this->buildContent($record);","sourceCodeStart":65,"sourceCodeEnd":101,"githubUrl":"https://github.com/Seldaek/monolog/blob/57eb1028342134e701e77c617565d51b6e5a2a53/src/Monolog/Handler/FlowdockHandler.php#L65-L101","documentation":"Error \"The FlowdockHandler must be configured (via setFormatter) with an instance of Monolog\\Formatter\\FlowdockFormatter to function correctly\" thrown in Seldaek/monolog.","triggerScenarios":"Thrown at src/Monolog/Handler/FlowdockHandler.php:83 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":"57eb1028342134e701e77c617565d51b6e5a2a53","analyzedAt":"2026-08-17T02:36:30.259Z","schemaVersion":2},"datasetVersion":"2026-08-17T04:17:16.089Z"}