{"record":{"id":"ac5c6a1d768fefbc","repo":"nodejs/node","slug":"results-regexp-at-the-wrong-level-regexp-should-n","errorCode":null,"errorMessage":"results_regexp at the wrong level. Regexp should not contain '%%s': results_regexp='%s' name=%s","messagePattern":"results_regexp at the wrong level\\. Regexp should not contain '%(.+?)': results_regexp='(.+?)' name=(.+?)","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"deps/v8/tools/run_perf.py","lineNumber":459,"sourceCode":"  def __init__(self, suite, parent, arch):\n    super(VariantConfig, self).__init__(suite, parent, arch)\n    assert \"variants\" in suite\n    for variant in suite.get('variants'):\n      assert \"variants\" not in variant, \\\n        \"Cannot directly nest variants:\" + str(variant)[:100]\n      assert \"name\" in variant, \\\n          \"Variant must have 'name' property: \" + str(variant)[:100]\n      assert len(variant) >= 2, \\\n          \"Variant must define other properties than 'name': \" + str(variant)\n\n\nclass LeafTraceConfig(GraphConfig):\n  \"\"\"Represents a leaf in the suite tree structure.\"\"\"\n  def __init__(self, suite, parent, arch):\n    super(LeafTraceConfig, self).__init__(suite, parent, arch)\n    assert self.results_regexp\n    if '%s' in self.results_regexp:\n      raise Exception(\n          \"results_regexp at the wrong level. \"\n          \"Regexp should not contain '%%s': results_regexp='%s' name=%s\" %\n          (self.results_regexp, self.name))\n\n  def AppendChild(self, node):\n    raise Exception(\"%s cannot have child configs.\" % type(self).__name__)\n\n  def ConsumeOutput(self, output, result_tracker):\n    \"\"\"Extracts trace results from the output.\n\n    Args:\n      output: Output object from the test run.\n      result_tracker: Result tracker to be updated.\n\n    Returns:\n      The raw extracted result value or None if an error occurred.\n    \"\"\"\n","sourceCodeStart":441,"sourceCodeEnd":477,"githubUrl":"https://github.com/nodejs/node/blob/1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e/deps/v8/tools/run_perf.py#L441-L477","documentation":"LeafTraceConfig represents a leaf of the suite tree; its results_regexp must be fully resolved (no `%s` placeholder). A `%s` here means a parent-level templated regexp leaked into a leaf un-substituted — i.e. the regexp is at the wrong tree level.","triggerScenarios":"A leaf suite whose resolved results_regexp literally contains the substring `%s`.","commonSituations":"Copy-pasting a parent-level templated regexp onto a leaf; missing an intermediate VariantConfig/GraphConfig layer that would have substituted the placeholder.","solutions":["Replace `%s` in the leaf's results_regexp with the literal name (or a concrete regex).","Move the templated regexp up to the parent so the leaf inherits an already-substituted regexp."],"exampleFix":"// before (leaf)\n\"results_regexp\": \"%s\\\\.Runtime: ([0-9]+)\"\n// after\n\"results_regexp\": \"MySuite\\\\.Runtime: ([0-9]+)\"","handlingStrategy":"validation","validationCode":"# When defining a leaf suite, ensure the regexp is fully resolved.\nassert '%s' not in leaf_regexp, (\n    f'leaf results_regexp must not contain a %s placeholder: {leaf_regexp!r}')","typeGuard":"def is_resolved_leaf_regexp(r):\n    return isinstance(r, str) and '%s' not in r","tryCatchPattern":null,"preventionTips":["Don't copy parent-level templated regexps onto leaves.","Add a suite-config presubmit that flags %s in leaf results_regexp."],"tags":["run-perf","regexp","config","v8","suite-tree"],"backgroundTag":null,"analyzedSha":"1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e","analyzedAt":"2026-08-13T00:53:24.642Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}