{"record":{"id":"e0a18118d87aa1ea","repo":"doctrine/orm","slug":"error-while-evaluating-regex-s","errorCode":null,"errorMessage":"Error while evaluating regex '/%s/'.","messagePattern":"Error while evaluating regex '/(.+?)/'\\.","errorType":"console","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"src/Tools/Console/MetadataFilter.php","lineNumber":65,"sourceCode":"        $this->filter = (array) $filter;\n\n        parent::__construct($metadata);\n    }\n\n    public function accept(): bool\n    {\n        if (count($this->filter) === 0) {\n            return true;\n        }\n\n        $it       = $this->getInnerIterator();\n        $metadata = $it->current();\n\n        foreach ($this->filter as $filter) {\n            $pregResult = preg_match('/' . $filter . '/', $metadata->getName());\n\n            if ($pregResult === false) {\n                throw new RuntimeException(\n                    sprintf(\"Error while evaluating regex '/%s/'.\", $filter),\n                );\n            }\n\n            if ($pregResult) {\n                return true;\n            }\n        }\n\n        return false;\n    }\n\n    /** @return ArrayIterator<int, ClassMetadata> */\n    public function getInnerIterator(): ArrayIterator\n    {\n        $innerIterator = parent::getInnerIterator();\n\n        assert($innerIterator instanceof ArrayIterator);","sourceCodeStart":47,"sourceCodeEnd":83,"githubUrl":"https://github.com/doctrine/orm/blob/d9b9ff73016bf598ae07515f97289ce8074e97a5/src/Tools/Console/MetadataFilter.php#L47-L83","documentation":"Error \"Error while evaluating regex '/%s/'.\" thrown in doctrine/orm.","triggerScenarios":"Thrown at src/Tools/Console/MetadataFilter.php:65 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":"d9b9ff73016bf598ae07515f97289ce8074e97a5","analyzedAt":"2026-08-21T06:13:15.863Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}