)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ffae7ab0ec2d7682543f6570c9b6af29c1077a87","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Tim Burke \u003ctim.burke@gmail.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-12-19 16:23:13 -0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Always set swift processes to use UTC"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Previously, we would set the TZ environment variable to the result of"},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"3a461143_ca062185","line":7,"updated":"2017-02-01 02:13:44.000000000","message":"I think the operator impact might be more clearly described with something like:\n\nSet swift processes to use UTC correctly on-purpose","commit_id":"523bc0ab71a4d976782a03c2beb46e5e8a25706b"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ffae7ab0ec2d7682543f6570c9b6af29c1077a87","unresolved":false,"context_lines":[{"line_number":38,"context_line":""},{"line_number":39,"context_line":"Now, set TZ to \"UTC+0\" and call tzset. Apparently we don\u0027t have a good"},{"line_number":40,"context_line":"way of getting local timezone info, we were (unintentionally?) using UTC"},{"line_number":41,"context_line":"before, and you should probably be running your servers in UTC anyway."},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"[1] https://docs.python.org/2/library/time.html#time.strftime"},{"line_number":44,"context_line":"[2] https://docs.python.org/2/library/time.html#id2"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"3a461143_aaec75bb","line":41,"updated":"2017-02-01 02:13:44.000000000","message":"+2","commit_id":"523bc0ab71a4d976782a03c2beb46e5e8a25706b"}],"swift/common/daemon.py":[{"author":{"_account_id":7233,"name":"Matthew Oliver","email":"matt@oliver.net.au","username":"mattoliverau"},"change_message_id":"7ffe16a755992032a679404b3afb591be7a22928","unresolved":false,"context_lines":[{"line_number":110,"context_line":""},{"line_number":111,"context_line":"    # Ensure TZ environment variable exists to avoid stat(\u0027/etc/localtime\u0027) on"},{"line_number":112,"context_line":"    # some platforms. This locks in reported times to UTC."},{"line_number":113,"context_line":"    os.environ[\u0027TZ\u0027] \u003d \u0027UTC+0\u0027"},{"line_number":114,"context_line":"    time.tzset()"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"    try:"}],"source_content_type":"text/x-python","patch_set":4,"id":"da36d5c6_3647814c","line":113,"updated":"2017-02-22 22:22:58.000000000","message":"You can get away with just \u0027UTC\u0027 here, in my tests this means UTC+0\n\nThis seens to work well for changing the date to UTC, so awesome. I did try to \u0027UTC+11\u0027 and it didn\u0027t give me Australian time, as it never changed the day.. But this isn\u0027t have the patch is doing, it\u0027s UTC, so great I guess.\n\n  In [34]: os.environ[\u0027TZ\u0027] \u003d \u0027UTC\u0027\n\n  In [35]: time.tzset()\n\n  In [36]: datetime.datetime.now()\n  Out[36]: datetime.datetime(2017, 2, 22, 22, 16, 32, 404019)\n\nThis is UTC at this time:\n\n  In [37]: os.environ[\u0027TZ\u0027] \u003d \u0027UTC+11\u0027\n\n  In [38]: time.tzset()\n\n  In [39]: datetime.datetime.now()\n  Out[39]: datetime.datetime(2017, 2, 22, 11, 17, 19, 412671)\n\nThis is not correct, as this time in Australia should be: \n\n  (2017, 2, 23, 8, 17, ...) \n\nNOTE: the day and hour is wrong.\n\nI want to try this with setting UTC+0 but after UTC has changed days (and before local timezone does) to see if the UTC+11 problem happens (ie doesn\u0027t change the day).","commit_id":"523bc0ab71a4d976782a03c2beb46e5e8a25706b"},{"author":{"_account_id":7233,"name":"Matthew Oliver","email":"matt@oliver.net.au","username":"mattoliverau"},"change_message_id":"f1fe3c440ad217ee104a48118c6b1d696dcda32f","unresolved":false,"context_lines":[{"line_number":110,"context_line":""},{"line_number":111,"context_line":"    # Ensure TZ environment variable exists to avoid stat(\u0027/etc/localtime\u0027) on"},{"line_number":112,"context_line":"    # some platforms. This locks in reported times to UTC."},{"line_number":113,"context_line":"    os.environ[\u0027TZ\u0027] \u003d \u0027UTC+0\u0027"},{"line_number":114,"context_line":"    time.tzset()"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"    try:"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba2be162_8fc40741","line":113,"in_reply_to":"da36d5c6_3647814c","updated":"2017-02-28 22:42:33.000000000","message":"right so this ENV does thing backwards.. which is stupid, but is how it works.\n\nMy timezone is UTC+11 but the env version of this is UTC-11.. yup swap the + to the - operator. Makes total sense. :P","commit_id":"523bc0ab71a4d976782a03c2beb46e5e8a25706b"}]}
