{"record":{"id":"0a73acc2d5ca1fd0","repo":"nodejs/node","slug":"s-d-fixup-failed-by-s-n","errorCode":null,"errorMessage":"%s:%d: Fixup failed by %s\\n","messagePattern":"(.+?):(.+?): Fixup failed by (.+?)\\\\n","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"deps/icu-small/source/tools/escapesrc/escapesrc.cpp","lineNumber":407,"sourceCode":"  // TODO: any platform variations of #line?\n  outf << \"#line 1 \\\"\" << infile << \"\\\"\" << '\\n';\n\n  int no = 0;\n  std::string linestr;\n  while( getline( inf, linestr)) {\n    no++;\n    if(fixLine(no, linestr)) {\n      goto fail;\n    }\n    outf << linestr << '\\n';\n  }\n\n  if(inf.eof()) {\n    return 0;\n  }\nfail:\n  outf.close();\n  fprintf(stderr, \"%s:%d: Fixup failed by %s\\n\", infile.c_str(), no, prog.c_str());\n  cleanup(outfile);\n  return 1;\n}\n\n/**\n * Main function\n */\nint main(int argc, const char *argv[]) {\n  prog = argv[0];\n\n  if(argc != 3) {\n    usage();\n    return 1;\n  }\n\n  std::string infile = argv[1];\n  std::string outfile = argv[2];\n","sourceCodeStart":389,"sourceCodeEnd":425,"githubUrl":"https://github.com/nodejs/node/blob/1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e/deps/icu-small/source/tools/escapesrc/escapesrc.cpp#L389-L425","documentation":"convert()'s main loop calls fixLine() per input line; if any line returns true (error), control jumps to the fail label, closes the output stream, prints this summary message naming the input file, line number, and program, deletes the partial output via cleanup(), and returns 1. It is a generic wrapper for all per-line fixup failures (741-745).","triggerScenarios":"Any fixLine() call returns true — i.e. one of the line-level errors (illegal code point, bad quote, u8'...' rejection, illegal UTF-8, etc.) occurred on line `no` of the input. The message reports the first such failing line.","commonSituations":"Feeding a source file containing a construct escapesrc cannot handle (see 741-745); an upstream code change introduced an unsupported literal; the input file is not actually the kind of C/C++ source escapesrc expects.","solutions":["Read the specific line number reported (no) in the input file and apply the fix corresponding to the underlying 741-745 error.","Re-run with verbose output to see which sub-error fired immediately before this summary.","If the construct is legitimate, exclude the file from the escapesrc pass or preprocess it."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"// after invoking escapesrc, inspect exit code and the per-line message\nrc = subprocess.run([...], capture_output=True)\nif rc.returncode != 0:\n    line = re.search(r':(\\d+):', rc.stderr.decode())  # parse the failing line\n    raise RuntimeError(f'escapesrc failed on line {line.group(1) if line else \"?\"}: {rc.stderr.decode()}')","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Treat any non-zero escapesrc exit as fatal; its output is deleted so partial results never propagate.","Echo escapesrc's stderr verbatim into the build log to speed root-cause of the underlying 741-745 error."],"tags":["icu","escapesrc","fixup","wrapper"],"backgroundTag":null,"analyzedSha":"1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e","analyzedAt":"2026-08-13T00:53:24.642Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}