{"record":{"id":"c0c79a733780d3af","repo":"dotnet/runtime","slug":"invalid-entry-line-in-exclusion-filename","errorCode":null,"errorMessage":"Invalid Entry {line}in {exclusion_filename}","messagePattern":"Invalid Entry (.+?)in (.+?)","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/coreclr/scripts/utilities.py","lineNumber":151,"sourceCode":"    if not os.path.isfile(exclusion_filename):\n        return exclusionInfo\n\n    with open(exclusion_filename,'r') as ExclusionFile:\n\n        for line in ExclusionFile:\n            line = line.strip()\n\n            #remove comments\n            if not line or line.startswith('#'):\n                continue\n\n            tokens = line.split(':')\n            #entries starting with nomac are ignored\n            if \"nomac\" in tokens:\n                continue\n\n            if len(tokens) > 5:\n                raise Exception(\"Invalid Entry \" + line + \"in \"+ exclusion_filename)\n\n            eventProvider = tokens[2]\n            eventTask     = tokens[1]\n            eventSymbol   = tokens[4]\n\n            if eventProvider == '':\n                eventProvider = \"*\"\n            if eventTask     == '':\n                eventTask     = \"*\"\n            if eventSymbol   == '':\n                eventSymbol   = \"*\"\n            entry = eventProvider + \":\" + eventTask + \":\" + eventSymbol\n\n            if tokens[0].lower() == \"nostack\":\n                exclusionInfo.nostack.add(entry)\n            if tokens[0].lower() == \"stack\":\n                exclusionInfo.explicitstack.add(entry)\n            if tokens[0].lower() == \"noclrinstanceid\":","sourceCodeStart":133,"sourceCodeEnd":169,"githubUrl":"https://github.com/dotnet/runtime/blob/60108ba66eb7d1d12f595480091b4ad80a24b172/src/coreclr/scripts/utilities.py#L133-L169","documentation":"Raised by parseExclusionList() in utilities.py at src/coreclr/scripts/utilities.py:151 when a non-comment line in the exclusion file has more than 5 colon-separated tokens. The expected format is up to 5 colon-separated fields (note: the message string also lacks a space before 'in', a cosmetic bug).","triggerScenarios":"An exclusion list file line with 6+ colon-separated tokens (an extra field, or an unescaped colon inside a value).","commonSituations":"Hand-editing an exclusion file and adding an extra segment; a corrupted copy; a trailing colon counting as an extra empty token.","solutions":["Inspect the line named in the message and reduce it to <=5 colon-separated tokens.","Escape or remove stray colons in field values.","Comment out malformed lines with '#' while debugging."],"exampleFix":"// before\nnostack:TaskName:ProviderName::SymbolName:extra\n// after\nnostack:TaskName:ProviderName::SymbolName","handlingStrategy":"validation","validationCode":"with open(exclusion_filename) as f:\n    for i, raw in enumerate(f, 1):\n        line = raw.strip()\n        if not line or line.startswith('#') or 'nomac' in line.split(':'):\n            continue\n        if len(line.split(':')) > 5:\n            raise SystemExit(f'{exclusion_filename}:{i} has >5 tokens: {line!r}')","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Lint exclusion files with a token-count check before the run.","Document the 5-field format in a header comment in the file."],"tags":["dotnet","coreclr","superpmi","config-file","parsing"],"backgroundTag":null,"analyzedSha":"60108ba66eb7d1d12f595480091b4ad80a24b172","analyzedAt":"2026-08-10T18:54:11.478Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}