{"record":{"id":"74d20bb032b02698","repo":"Fission-AI/OpenSpec","slug":"some-rules-for-artifactid-are-empty-strings","errorCode":null,"errorMessage":"Some rules for '${artifactId}' are empty strings, ignoring them","messagePattern":"Some rules for '(.+?)' are empty strings, ignoring them","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/core/project-config.ts","lineNumber":337,"sourceCode":"        // Artifact ids are intentionally not restricted to the built-in naming\n        // convention, so keys such as \"constructor\" remain valid for custom\n        // schemas. A null-prototype map preserves those keys as data without\n        // letting \"__proto__\" mutate the lookup object's prototype.\n        const parsedRules: Record<string, string[]> = Object.create(null);\n        let hasValidRules = false;\n\n        for (const [artifactId, rules] of Object.entries(raw.rules)) {\n          const rulesArrayResult = z.array(z.string()).safeParse(rules);\n\n          if (rulesArrayResult.success) {\n            // Filter out empty strings\n            const validRules = rulesArrayResult.data.filter((r) => r.length > 0);\n            if (validRules.length > 0) {\n              parsedRules[artifactId] = validRules;\n              hasValidRules = true;\n            }\n            if (validRules.length < rulesArrayResult.data.length) {\n              console.warn(\n                `Some rules for '${artifactId}' are empty strings, ignoring them`\n              );\n            }\n          } else {\n            console.warn(\n              `Rules for '${artifactId}' must be an array of strings, ignoring this artifact's rules`\n            );\n          }\n        }\n\n        if (hasValidRules) {\n          config.rules = parsedRules;\n        }\n      } else {\n        console.warn(`Invalid 'rules' field in config (must be object)`);\n      }\n    }\n","sourceCodeStart":319,"sourceCodeEnd":355,"githubUrl":"https://github.com/Fission-AI/OpenSpec/blob/6926ccb18afa4ff621112813e9968334576ee11a/src/core/project-config.ts#L319-L355","documentation":"Error \"Some rules for '${artifactId}' are empty strings, ignoring them\" thrown in Fission-AI/OpenSpec.","triggerScenarios":"Thrown at src/core/project-config.ts:337 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":"6926ccb18afa4ff621112813e9968334576ee11a","analyzedAt":"2026-08-25T12:29:45.729Z","schemaVersion":2},"datasetVersion":"2026-08-25T16:17:27.014Z"}