)]}'
{
  "commit": "aac7c279c65fac36b116b0ebcf77e88581b60071",
  "tree": "a0c0cc8a73a5aa98208c430e33584eea88ce244d",
  "parents": [
    "1a9fc6149393d0e9c175318e456660cef73fb327"
  ],
  "author": {
    "name": "Neri Marschik",
    "email": "nerima@google.com",
    "time": "Wed Dec 17 09:47:43 2025 +0900"
  },
  "committer": {
    "name": "GN LUCI",
    "email": "gn-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Tue Jan 06 16:48:51 2026 -0800"
  },
  "message": "Improve error message for rebase_path builtin\n\nWhen rebase_path encounters an invalid path (e.g., an empty string), it\npreviously blamed the origin of the value. If the value originated from\nanother function (like read_file) or a variable definition far away,\nthe error message could be confusing as it pointed to the definition\nsite rather than the usage site.\n\nThis change improves the error reporting by:\n- Rewriting the error to blame the rebase_path call.\n- Appending the original error location as a sub-error. This makes it clear that\nrebase_path failed, while still providing context on where the bad value came\nfrom.\n\nBefore\n```\nERROR at //BUILD.gn:2:9: Empty directory path.\nlines \u003d read_file(\"test.txt\", \"list lines\")\n\t^---------------------------------\nYou can\u0027t use empty strings as directories.\n```\n\nAfter\n```\nERROR at //BUILD.gn:4:13: Empty directory path.\nrebase_path(lines)\n\t    ^----\nYou can\u0027t use empty strings as directories.\nSee //BUILD.gn:3:9: The value that caused the error.\nlines \u003d read_file(\"test.txt\", \"list lines\")\n\t^\n```\n\nChange-Id: I7c5d26ee13ac5fea3560a808a9d4262a0b9304fc\nReviewed-on: https://gn-review.googlesource.com/c/gn/+/20660\nReviewed-by: David Turner \u003cdigit@google.com\u003e\nCommit-Queue: Neri Marschik \u003cnerima@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "7e912aa1a5eff4187183709a7b7875c4a240c79e",
      "old_mode": 33188,
      "old_path": "src/gn/function_rebase_path.cc",
      "new_id": "a9987851f8c99e35162eb9a5238b5b0fae2e9866",
      "new_mode": 33188,
      "new_path": "src/gn/function_rebase_path.cc"
    }
  ]
}
