)]}'
{
  "commit": "4aa4b211c62a8f01abfe1953b4274af69d374ecf",
  "tree": "7e0881b72c6401f3b6101de46fecb4f6e4bee1e8",
  "parents": [
    "203153e7bba61b1b2d782e9e75aef919eab0d54b"
  ],
  "author": {
    "name": "Mike Frysinger",
    "email": "vapier@google.com",
    "time": "Fri Mar 04 15:03:00 2016 -0500"
  },
  "committer": {
    "name": "Mike Frysinger",
    "email": "vapier@google.com",
    "time": "Sat Mar 05 21:52:31 2016 +0000"
  },
  "message": "RepoHook: set __file__ when running the hook\n\nA common design pattern is to use __file__ to find the location of the\nactive python module to assist in output or loading of related assets.\nThe current hook systems runs the pre-upload.py hook in a context w/out\nthat set leading to runtime errors:\n\n$ repo upload --cbr .\nERROR: Traceback (most recent call last):\n  File \".../repo/project.py\", line 481, in _ExecuteHook\n    self._script_fullpath, \u0027exec\u0027), context)\n  File \".../repohooks/pre-upload.py\", line 32, in \u003cmodule\u003e\n    path \u003d os.path.dirname(os.path.realpath(__file__))\nNameError: name \u0027__file__\u0027 is not defined\n\nDefine this variable in this context so code can safely use it.\n\nChange-Id: If6331312445fa61d9351b59f83abcc1c99ae6748\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "d54e336c9dcecc3c0bab2c2cca74541a0b6f1e25",
      "old_mode": 33188,
      "old_path": "project.py",
      "new_id": "4c5fa9e5159926c8f6b519ed0f525d20871e4ad8",
      "new_mode": 33188,
      "new_path": "project.py"
    }
  ]
}
