{"record":{"id":"b82d2ad5fec0dc5b","repo":"nodejs/node","slug":"unknown-debug-format-s","errorCode":null,"errorMessage":"Unknown debug format %s","messagePattern":"Unknown debug format (.+?)","errorType":"exception","errorClass":"NotImplementedError","httpStatus":null,"severity":"error","filePath":"tools/gyp/pylib/gyp/xcode_emulation.py","lineNumber":617,"sourceCode":"            # TODO: In this case, it depends on the target. xcode passes\n            # mdynamic-no-pic by default for executable and possibly static lib\n            # according to mento\n\n        if self._Test(\"GCC_ENABLE_PASCAL_STRINGS\", \"YES\", default=\"YES\"):\n            cflags.append(\"-mpascal-strings\")\n\n        self._Appendf(cflags, \"GCC_OPTIMIZATION_LEVEL\", \"-O%s\", default=\"s\")\n\n        if self._Test(\"GCC_GENERATE_DEBUGGING_SYMBOLS\", \"YES\", default=\"YES\"):\n            dbg_format = self._Settings().get(\"DEBUG_INFORMATION_FORMAT\", \"dwarf\")\n            if dbg_format == \"dwarf\":\n                cflags.append(\"-gdwarf-2\")\n            elif dbg_format == \"stabs\":\n                raise NotImplementedError(\"stabs debug format is not supported yet.\")\n            elif dbg_format == \"dwarf-with-dsym\":\n                cflags.append(\"-gdwarf-2\")\n            else:\n                raise NotImplementedError(\"Unknown debug format %s\" % dbg_format)\n\n        if self._Settings().get(\"GCC_STRICT_ALIASING\") == \"YES\":\n            cflags.append(\"-fstrict-aliasing\")\n        elif self._Settings().get(\"GCC_STRICT_ALIASING\") == \"NO\":\n            cflags.append(\"-fno-strict-aliasing\")\n\n        if self._Test(\"GCC_SYMBOLS_PRIVATE_EXTERN\", \"YES\", default=\"NO\"):\n            cflags.append(\"-fvisibility=hidden\")\n\n        if self._Test(\"GCC_TREAT_WARNINGS_AS_ERRORS\", \"YES\", default=\"NO\"):\n            cflags.append(\"-Werror\")\n\n        if self._Test(\"GCC_WARN_ABOUT_MISSING_NEWLINE\", \"YES\", default=\"NO\"):\n            cflags.append(\"-Wnewline-eof\")\n\n        # In Xcode, this is only activated when GCC_COMPILER_VERSION is clang or\n        # llvm-gcc. It also requires a fairly recent libtool, and\n        # if the system clang isn't used, DYLD_LIBRARY_PATH needs to contain the","sourceCodeStart":599,"sourceCodeEnd":635,"githubUrl":"https://github.com/nodejs/node/blob/1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e/tools/gyp/pylib/gyp/xcode_emulation.py#L599-L635","documentation":"Raised by XcodeSettings._GetDebuggingFlags when DEBUG_INFORMATION_FORMAT is set to a value that is none of 'dwarf', 'stabs', or 'dwarf-with-dsym'. The error message interpolates the unrecognized value so you can identify the offending setting. This protects against silent miscompilation by failing fast on an unknown debug format.","triggerScenarios":"A target's xcode_settings dict has DEBUG_INFORMATION_FORMAT set to a typo or a value not in the handled set — for example 'DWARF' (wrong case), 'dwarf2', 'none', or any arbitrary string. The final else branch in the debug-format chain raises.","commonSituations":"Typo in the format string. Copy-pasting a newer Xcode build setting value not yet understood by this gyp version. Case mismatch (Xcode build settings are usually lowercase here).","solutions":["Correct the DEBUG_INFORMATION_FORMAT value to one of: 'dwarf', 'dwarf-with-dsym', or 'stabs'.","Check for case sensitivity — use exactly lowercase 'dwarf'.","Remove the key to fall back to the 'dwarf' default.","Upgrade the gyp checkout if you believe the value is a legitimately new Xcode format."],"exampleFix":"# before\n'DEBUG_INFORMATION_FORMAT': 'DWARFF',\n# after\n'DEBUG_INFORMATION_FORMAT': 'dwarf',","handlingStrategy":"validation","validationCode":"# Validate DEBUG_INFORMATION_FORMAT before gyp generation\n_VALID = {'dwarf', 'dwarf-with-dsym', 'stabs'}\nfmt = config.get('DEBUG_INFORMATION_FORMAT', 'dwarf')\nif fmt not in _VALID:\n    raise ValueError(f'DEBUG_INFORMATION_FORMAT must be one of {_VALID}, got {fmt!r}')","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Double-check spelling and casing of DEBUG_INFORMATION_FORMAT values.","Keep a lint or pre-commit check on xcode_settings keys."],"tags":["xcode","gyp","macos","debugging","configuration"],"backgroundTag":null,"analyzedSha":"1b2de5e052fc0fb95fd7fb6846dcec4ade598e9e","analyzedAt":"2026-08-13T00:53:24.642Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}