{"record":{"id":"078b59f37b30dcd1","repo":"dotnet/runtime","slug":"invalid-entry-line-in-inclusion-filename","errorCode":null,"errorMessage":"Invalid Entry {line}in {inclusion_filename}","messagePattern":"Invalid Entry (.+?)in (.+?)","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/coreclr/scripts/utilities.py","lineNumber":195,"sourceCode":"\n    if not os.path.isfile(inclusion_filename):\n        return inclusion_list\n\n    with open(inclusion_filename,'r') as InclusionFile:\n        for line in InclusionFile:\n            line = line.strip()\n\n            #remove comments\n            if not line or line.startswith('#'):\n                continue\n\n            tokens = line.split(':')\n\n            if len(tokens) == 0:\n                continue\n\n            if len(tokens) > 2:\n                raise Exception(\"Invalid Entry \" + line + \"in \"+ inclusion_filename)\n\n            providerName = \"\"\n            eventName = \"\"\n\n            if len(tokens) == 2:\n                providerName = tokens[0]\n                eventName = tokens[1]\n\n            if len(tokens) == 1:\n                providerName = \"*\"\n                eventName = tokens[0]\n\n            if providerName not in inclusion_list:\n                inclusion_list[providerName] = set()\n\n            inclusion_list[providerName].add(eventName)\n\n    return inclusion_list","sourceCodeStart":177,"sourceCodeEnd":213,"githubUrl":"https://github.com/dotnet/runtime/blob/290d5ab72cc1102813fbc0406fb186ceadabc340/src/coreclr/scripts/utilities.py#L177-L213","documentation":"Raised by parseInclusionList in utilities.py for a line whose `:`-split yields more than 2 tokens. Inclusion entries are either `eventName` or `providerName:eventName`; a third field is invalid. (Note the missing-space-before-'in' message bug, identical to the exclusion variant.)","triggerScenarios":"An inclusion-file line contains 3+ colon-separated fields, e.g. `Provider:Task:Event` copied from exclusion syntax.","commonSituations":"Mixing exclusion (5-field) syntax into the inclusion (2-field) file; stray colons; editor auto-wrap inserting ':'; copy-paste from the wrong template.","solutions":["Open the inclusion file and fix the printed `{line}` to at most 2 colon fields.","Confirm you are editing the inclusion file, not the exclusion file (different field counts).","Strip trailing colons and re-validate line-by-line.","Comment out (`#`) any line you can't immediately classify."],"exampleFix":"// before\nProvider:Task:Event  // 3 tokens -> raises [199]\n// after\nProvider:Event","handlingStrategy":"validation","validationCode":"with open(inclusion_filename) as fh:\n    for i, raw in enumerate(fh, 1):\n        line = raw.strip()\n        if not line or line.startswith('#'): continue\n        if len(line.split(':')) > 2:\n            raise SystemExit(f'inclusion line {i} has >2 fields: {line!r}')","typeGuard":"def inclusion_line_valid(line: str) -> bool:\n    return len(line.split(':')) <= 2","tryCatchPattern":"try:\n    parseInclusionList(inclusion_filename)\nexcept Exception as e:\n    if 'Invalid Entry' in str(e) and inclusion_filename in str(e):\n        print('fix the printed inclusion line, then rerun'); raise","preventionTips":["Keep inclusion files to 1-2 colon fields","Don't paste exclusion (5-field) syntax into inclusion files","Lint inclusion files in CI"],"tags":["configuration","parsing","utilities","validation"],"analyzedSha":"290d5ab72cc1102813fbc0406fb186ceadabc340","analyzedAt":"2026-08-06T19:57:01.276Z","schemaVersion":2},"datasetVersion":"2026-08-06T23:17:07.152Z"}