)]}'
{"keystone/auth/controllers.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":"    "},{"line_number":302,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BNbg%3D","line":302,"updated":"2014-01-29 02:07:35.000000000","message":"one of the \"cadf\"s needs to be removed from this line to clean up the api a bit\n\n\u0027authenticate\u0027 is also a verb -- shouldn\u0027t this be a noun (authentication?), or past tense verb (authenticated)? although, a past tense verb implies success... thoughts?","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":"    "},{"line_number":302,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMi8%3D","line":302,"in_reply_to":"AAAAUH%2F%2BMvk%3D","updated":"2014-01-29 06:53:34.000000000","message":"probably a good idea. I wanted to write this from scratch and kept it separate from notifications initially but as I finish it if it makes sense I can move it into notifications.py","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"b9253bd9362eb047010a53d8c0b35c3035061c19","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":"    "},{"line_number":302,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMvk%3D","line":302,"in_reply_to":"AAAAUH%2F%2BNbg%3D","updated":"2014-01-29 05:35:08.000000000","message":"cadf_notifications.send_event() ?\n\ncurious, why don\u0027t we append the cadf_notifications code to the existing keystone/notifications.py file?","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":"    "},{"line_number":302,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMjE%3D","line":302,"in_reply_to":"AAAAUH%2F%2BNbg%3D","updated":"2014-01-29 06:53:34.000000000","message":"will remove one of the cadfs.  \n\nWould like to keep authenticate because that maps directly to a CADF_Event action type that I am required to use","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"import six"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"from keystone import cadf_notifications"},{"line_number":22,"context_line":"from keystone.common import cms"},{"line_number":23,"context_line":"from keystone.common import controller"},{"line_number":24,"context_line":"from keystone.common import dependency"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyaE%3D","line":21,"updated":"2014-02-10 20:20:25.000000000","message":"subsequent patch: change this to something like:\n\n  from keystone.notification import audit\n\nper morganfainberg and ayoung","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"import six"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"from keystone import cadf_notifications"},{"line_number":22,"context_line":"from keystone.common import cms"},{"line_number":23,"context_line":"from keystone.common import controller"},{"line_number":24,"context_line":"from keystone.common import dependency"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FutE%3D","line":21,"in_reply_to":"AAAAUX%2F%2FyaE%3D","updated":"2014-02-11 06:55:33.000000000","message":"I have done everything else.  This one should be easy but before I attempt this one I want to ask the experts on IRC what needs to be done here","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyaM%3D","line":302,"updated":"2014-02-10 20:20:25.000000000","message":"so this will become @audit.emit_event(\u0027authenticate\u0027) in a subsequent patch","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"78267f5d2dac9ef114710b4b248a77108f96c564","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyVE%3D","line":302,"updated":"2014-02-10 20:32:44.000000000","message":"we only care about v3? I would expect the same change in \n\nkeystone/token/controller.py?","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c8945d8cb7499579e02d2b681dcc08c5b2df9b6d","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FxvI%3D","line":302,"in_reply_to":"AAAAUX%2F%2FyVE%3D","updated":"2014-02-10 21:41:37.000000000","message":"guang, it\u0027ll be added to token/controller too","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":299,"context_line":"        super(Auth, self).__init__(*args, **kw)"},{"line_number":300,"context_line":"        config.setup_authentication()"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":303,"context_line":"    def authenticate_for_token(self, context, auth\u003dNone):"},{"line_number":304,"context_line":"        \"\"\"Authenticate user and issue a token.\"\"\""},{"line_number":305,"context_line":"        include_catalog \u003d \u0027nocatalog\u0027 not in context[\u0027query_string\u0027]"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fuss%3D","line":302,"in_reply_to":"AAAAUX%2F%2FyaM%3D","updated":"2014-02-11 06:55:33.000000000","message":"See above comment. I want to ask about this before I attempt it. Hopefully I took care of all the hard stuff first","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"}],"keystone/cadf_notifications.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":28,"context_line":"    \"\"\"Send cadf event notifications for various methods."}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BNa0%3D","line":25,"updated":"2014-01-29 02:07:35.000000000","message":"in the keystone working directory, run either \"flake8 .\" or \"tox -e pep8\" to find the little issues causing the pep8 check failures","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":28,"context_line":"    \"\"\"Send cadf event notifications for various methods."}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMis%3D","line":25,"in_reply_to":"AAAAUH%2F%2BNa0%3D","updated":"2014-01-29 06:53:34.000000000","message":"will do.","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":35,"context_line":"        print(\"BT cadf_action \u003d \")"},{"line_number":36,"context_line":"        print(self.cadf_action)"},{"line_number":37,"context_line":"        #print(\"BT About to print resource_type\")"},{"line_number":38,"context_line":"        #print(resource_type)"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def __call__(self, f):"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BNbA%3D","line":38,"updated":"2014-01-29 02:07:35.000000000","message":"same as below","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def __call__(self, f):"},{"line_number":42,"context_line":"        "},{"line_number":43,"context_line":"        print(\"BT inside __call__\")"},{"line_number":44,"context_line":"        print(f)"},{"line_number":45,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":46,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BNbM%3D","line":43,"updated":"2014-01-29 02:07:35.000000000","message":"remove the print statements, or covert to LOG.debug() where appropriate","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def __call__(self, f):"},{"line_number":42,"context_line":"        "},{"line_number":43,"context_line":"        print(\"BT inside __call__\")"},{"line_number":44,"context_line":"        print(f)"},{"line_number":45,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":46,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMic%3D","line":43,"in_reply_to":"AAAAUH%2F%2BNbM%3D","updated":"2014-01-29 06:53:34.000000000","message":"will remove. as it may be painfully obvious I was writing my first decorator and really wanted to understand what was happening.  The fact that whether or not the decorator has arguments affects whether the function is passed to __init__ or __call__ blows my mind.","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"b9253bd9362eb047010a53d8c0b35c3035061c19","unresolved":false,"context_lines":[{"line_number":48,"context_line":"                print(\"CADF ABout to call f\")"},{"line_number":49,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":50,"context_line":"            except Exception:"},{"line_number":51,"context_line":"                # For authentication failure send a cadf event as well"},{"line_number":52,"context_line":"                print(\"CADF Send Authentication Failed\")"},{"line_number":53,"context_line":"                _send_notification(self.cadf_action)"},{"line_number":54,"context_line":"                raise"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMv4%3D","line":51,"updated":"2014-01-29 05:35:08.000000000","message":"thanks for comment, i was about to ask you to remove line 53, but why do we send events if it had an exception?","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":48,"context_line":"                print(\"CADF ABout to call f\")"},{"line_number":49,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":50,"context_line":"            except Exception:"},{"line_number":51,"context_line":"                # For authentication failure send a cadf event as well"},{"line_number":52,"context_line":"                print(\"CADF Send Authentication Failed\")"},{"line_number":53,"context_line":"                _send_notification(self.cadf_action)"},{"line_number":54,"context_line":"                raise"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMiU%3D","line":51,"in_reply_to":"AAAAUH%2F%2BMv4%3D","updated":"2014-01-29 06:53:34.000000000","message":"I believe it is to record that the authentication failed for auditing purposes.  Would need to ask Matt Rutkowski why they added this to the CADF spec","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5d934ccf3f3f781963ede38eb73b5378504ea5d8","unresolved":false,"context_lines":[{"line_number":24,"context_line":"from pycadf import eventfactory"},{"line_number":25,"context_line":"from pycadf import host"},{"line_number":26,"context_line":"from pycadf import identifier"},{"line_number":27,"context_line":"from pycadf import resource"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"LOG \u003d log.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F99Hw%3D","line":27,"updated":"2014-01-31 17:54:34.000000000","message":"3rd party modules are imported before imports from keystone","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1d5c78f73d1dfadd8ed671964abae6f80ae92095","unresolved":false,"context_lines":[{"line_number":24,"context_line":"from pycadf import eventfactory"},{"line_number":25,"context_line":"from pycadf import host"},{"line_number":26,"context_line":"from pycadf import identifier"},{"line_number":27,"context_line":"from pycadf import resource"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"LOG \u003d log.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F95JM%3D","line":27,"in_reply_to":"AAAAUH%2F99Hw%3D","updated":"2014-02-02 06:32:30.000000000","message":"Done","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5d934ccf3f3f781963ede38eb73b5378504ea5d8","unresolved":false,"context_lines":[{"line_number":45,"context_line":"            remote_addr \u003d None"},{"line_number":46,"context_line":"            http_user_agent \u003d None"},{"line_number":47,"context_line":"            user_name \u003d None"},{"line_number":48,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":49,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027, None)"},{"line_number":50,"context_line":"            if environment:"},{"line_number":51,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027, None)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F99IU%3D","line":48,"updated":"2014-01-31 17:54:34.000000000","message":"if this should be a doc string (which looks to be the case), it should be at the top of the function definition before any code... if this should be an inline comment, it should use # instead of triple quotes","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1d5c78f73d1dfadd8ed671964abae6f80ae92095","unresolved":false,"context_lines":[{"line_number":45,"context_line":"            remote_addr \u003d None"},{"line_number":46,"context_line":"            http_user_agent \u003d None"},{"line_number":47,"context_line":"            user_name \u003d None"},{"line_number":48,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":49,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027, None)"},{"line_number":50,"context_line":"            if environment:"},{"line_number":51,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027, None)"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F95JI%3D","line":48,"in_reply_to":"AAAAUH%2F99IU%3D","updated":"2014-02-02 06:32:30.000000000","message":"Done","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5d934ccf3f3f781963ede38eb73b5378504ea5d8","unresolved":false,"context_lines":[{"line_number":61,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":62,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":63,"context_line":"                                   user_name\u003duser_name,"},{"line_number":64,"context_line":"                                   outcome\u003d\u0027pending\u0027)"},{"line_number":65,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":66,"context_line":"            except Exception:"},{"line_number":67,"context_line":"                # For authentication failure send a cadf event as well"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F99Ik%3D","line":64,"updated":"2014-01-31 17:54:34.000000000","message":"this _send_notification() shouldn\u0027t be in the try block - if it fails, it will trigger an irrelevant cadf failure notification","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1d5c78f73d1dfadd8ed671964abae6f80ae92095","unresolved":false,"context_lines":[{"line_number":61,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":62,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":63,"context_line":"                                   user_name\u003duser_name,"},{"line_number":64,"context_line":"                                   outcome\u003d\u0027pending\u0027)"},{"line_number":65,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":66,"context_line":"            except Exception:"},{"line_number":67,"context_line":"                # For authentication failure send a cadf event as well"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAAUH%2F95JE%3D","line":64,"in_reply_to":"AAAAUH%2F99Ik%3D","updated":"2014-02-02 06:32:30.000000000","message":"Done","commit_id":"0fd70b28d5257adc0e519f18602420e92f4c1ec9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"4ea3f690c803d2e4e83cfa637e4a826434d62926","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d host.Host(address\u003dremote_addr, agent\u003dhttp_user_agent)"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAUH%2F94WA%3D","line":106,"updated":"2014-02-02 19:42:33.000000000","message":"(NIT): even though this is a private method, could the docstrings for the parameters be added?","commit_id":"9091e4ca813da3179f8d0eba0df2bebfd88bd818"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"ae1ca4ac4146a49a1ad809aed9e0be8765abe6b3","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d host.Host(address\u003dremote_addr, agent\u003dhttp_user_agent)"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAUH%2F94GM%3D","line":106,"in_reply_to":"AAAAUH%2F94Go%3D","updated":"2014-02-02 19:50:22.000000000","message":"++ can\u0027t disagree with that :)","commit_id":"9091e4ca813da3179f8d0eba0df2bebfd88bd818"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"4970f30661b9faa586ed325a80ed9863f70c192e","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d host.Host(address\u003dremote_addr, agent\u003dhttp_user_agent)"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAAUH%2F94Go%3D","line":106,"in_reply_to":"AAAAUH%2F94WA%3D","updated":"2014-02-02 19:48:11.000000000","message":"will fix it. Looks like I was sending up patch set 6 when you were reviewing patchset 5. So I will address all your comments in patch set 7. But will wait till perhaps after the super bowl :-)","commit_id":"9091e4ca813da3179f8d0eba0df2bebfd88bd818"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0f9a4a60a94aac1545d81335f79992d3510e76c7","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2014 IBM Corp."},{"line_number":4,"context_line":"#"},{"line_number":5,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":6,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F94Gg%3D","line":3,"updated":"2014-02-02 20:14:07.000000000","message":"I think we can remove this line here. According to dolphm, developers don\u0027t need to add copyrights unless they work directly for the OpenStack Foundation. \n\nDolph might have to keep me honest on that part. See discussion here: \n\nhttps://review.openstack.org/#/c/58311/5/keystone/tests/fixtures/__init__.py","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2014 IBM Corp."},{"line_number":4,"context_line":"#"},{"line_number":5,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":6,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXc%3D","line":3,"in_reply_to":"AAAAUH%2F94Gg%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"747684d48534b44cdc84790b058c464303a36e43","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"# Copyright 2014 IBM Corp."},{"line_number":4,"context_line":"#"},{"line_number":5,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":6,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xIA%3D","line":3,"in_reply_to":"AAAAUH%2F94Gg%3D","updated":"2014-02-04 06:23:58.000000000","message":"Upon further review let\u0027s discuss.  I think Dolph\u0027s comments were regarding openstack foundation copyrights not IBM copyrights.  I just saw morgan fainberg add a copyright for his company so I think that is the distinction","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":14,"context_line":"#   License for the specific language governing permissions and limitations"},{"line_number":15,"context_line":"#   under the License."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"\"\"\" CADF Notifications module for OpenStack Identity Service resources\"\"\""},{"line_number":18,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":19,"context_line":"from pycadf import eventfactory"},{"line_number":20,"context_line":"from pycadf import host"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xfQ%3D","line":17,"updated":"2014-02-04 04:46:06.000000000","message":"I think we can get rid of this line, if someone wants info on the library they can look it up.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":14,"context_line":"#   License for the specific language governing permissions and limitations"},{"line_number":15,"context_line":"#   under the License."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"\"\"\" CADF Notifications module for OpenStack Identity Service resources\"\"\""},{"line_number":18,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":19,"context_line":"from pycadf import eventfactory"},{"line_number":20,"context_line":"from pycadf import host"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXg%3D","line":17,"in_reply_to":"AAAAUH%2F9xfQ%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0f9a4a60a94aac1545d81335f79992d3510e76c7","unresolved":false,"context_lines":[{"line_number":17,"context_line":"\"\"\" CADF Notifications module for OpenStack Identity Service resources\"\"\""},{"line_number":18,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":19,"context_line":"from pycadf import eventfactory"},{"line_number":20,"context_line":"from pycadf import host"},{"line_number":21,"context_line":"from pycadf import identifier"},{"line_number":22,"context_line":"from pycadf import resource"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F94EY%3D","line":20,"updated":"2014-02-02 20:14:07.000000000","message":"This should be renamed to something that is more descriptive of the module we are using it from, to not be confused with \u0027self.host\u0027 within the CadfNotificationWrapper class.\n\nMaybe: \n\n    from pycadf import host as pycadf_host\n\n?","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":17,"context_line":"\"\"\" CADF Notifications module for OpenStack Identity Service resources\"\"\""},{"line_number":18,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":19,"context_line":"from pycadf import eventfactory"},{"line_number":20,"context_line":"from pycadf import host"},{"line_number":21,"context_line":"from pycadf import identifier"},{"line_number":22,"context_line":"from pycadf import resource"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXk%3D","line":20,"in_reply_to":"AAAAUH%2F94EY%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":31,"context_line":"    \"\"\"Send cadf event notifications for various methods."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    Sends notifications for events such as whether an authentication was"},{"line_number":34,"context_line":"    successful or not."}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xfM%3D","line":31,"updated":"2014-02-04 04:46:06.000000000","message":"capitalize CADF","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":31,"context_line":"    \"\"\"Send cadf event notifications for various methods."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    Sends notifications for events such as whether an authentication was"},{"line_number":34,"context_line":"    successful or not."}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXo%3D","line":31,"in_reply_to":"AAAAUH%2F9xfM%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":30,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":31,"context_line":"    \"\"\"Send cadf event notifications for various methods."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    Sends notifications for events such as whether an authentication was"},{"line_number":34,"context_line":"    successful or not."},{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":"    def __init__(self, action, host\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xeE%3D","line":33,"updated":"2014-02-04 04:46:06.000000000","message":"\"Sends CADF notifications ...\"","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":30,"context_line":"class CadfNotificationWrapper(object):"},{"line_number":31,"context_line":"    \"\"\"Send cadf event notifications for various methods."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    Sends notifications for events such as whether an authentication was"},{"line_number":34,"context_line":"    successful or not."},{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":"    def __init__(self, action, host\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXs%3D","line":33,"in_reply_to":"AAAAUH%2F9xeE%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0f9a4a60a94aac1545d81335f79992d3510e76c7","unresolved":false,"context_lines":[{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":"    def __init__(self, action, host\u003dNone):"},{"line_number":37,"context_line":"        self.cadf_action \u003d action"},{"line_number":38,"context_line":"        self.host \u003d host"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def __call__(self, f):"},{"line_number":41,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F94C8%3D","line":38,"updated":"2014-02-02 20:14:07.000000000","message":"\u0027host\u0027 from a notification standpoint is used for getting a publisher_id I believe: \n\nhttps://github.com/openstack/keystone/blob/master/keystone/notifications.py#L147\n\nbut I don\u0027t think it is a required parameter by the notifier_api: \n\nhttps://github.com/openstack/keystone/blob/master/keystone/openstack/common/notifier/api.py#L86\n\nI think Jamie Lennox was working on taking \u0027host\u0027 out and just defaulting to generating the publisher_id with default values, similar to below:\n\nhttps://github.com/jamielennox/keystone/commit/b3e81c32d9fc2a68c648f3f13b1805282f01444b\n\nsince publisher_id is no longer calculated in the oslo.messaging notifier api: \n\nhttps://github.com/openstack/oslo.messaging/blob/master/oslo/messaging/notify/notifier.py","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":"    def __init__(self, action, host\u003dNone):"},{"line_number":37,"context_line":"        self.cadf_action \u003d action"},{"line_number":38,"context_line":"        self.host \u003d host"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def __call__(self, f):"},{"line_number":41,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xX0%3D","line":38,"in_reply_to":"AAAAUH%2F94C8%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":46,"context_line":"            user_name \u003d None"},{"line_number":47,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027, None)"},{"line_number":48,"context_line":"            if environment:"},{"line_number":49,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027, None)"},{"line_number":50,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027, None)"},{"line_number":51,"context_line":"                openstack_params \u003d environment.get(\u0027openstack.params\u0027, None)"},{"line_number":52,"context_line":"                if openstack_params:"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xdc%3D","line":49,"updated":"2014-02-04 04:46:06.000000000","message":"You don\u0027t need to default to None, thats the normal behaviour","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":46,"context_line":"            user_name \u003d None"},{"line_number":47,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027, None)"},{"line_number":48,"context_line":"            if environment:"},{"line_number":49,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027, None)"},{"line_number":50,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027, None)"},{"line_number":51,"context_line":"                openstack_params \u003d environment.get(\u0027openstack.params\u0027, None)"},{"line_number":52,"context_line":"                if openstack_params:"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xWs%3D","line":49,"in_reply_to":"AAAAUH%2F9xdc%3D","updated":"2014-02-04 05:43:51.000000000","message":"GREAT CATCH.  Thank you for keeping me from looking dumb :-).  Much appreciated!!!","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":54,"context_line":"                    if auth:"},{"line_number":55,"context_line":"                        user_name \u003d _get_user_name_from_auth(auth)"},{"line_number":56,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":57,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":58,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":59,"context_line":"                               user_name\u003duser_name,"},{"line_number":60,"context_line":"                               outcome\u003d\u0027pending\u0027)"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xdg%3D","line":57,"updated":"2014-02-04 04:46:06.000000000","message":"you can remove defaulting of line 44, 45, and 46, and just set these other values in the caller to None. ... \n\nunless you do this because you want to re-use them in the except and else blocks.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":54,"context_line":"                    if auth:"},{"line_number":55,"context_line":"                        user_name \u003d _get_user_name_from_auth(auth)"},{"line_number":56,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":57,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":58,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":59,"context_line":"                               user_name\u003duser_name,"},{"line_number":60,"context_line":"                               outcome\u003d\u0027pending\u0027)"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xXU%3D","line":57,"in_reply_to":"AAAAUH%2F9xdg%3D","updated":"2014-02-04 05:43:51.000000000","message":"yes these are reused in the except block","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":66,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":67,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":68,"context_line":"                                   user_name\u003duser_name,"},{"line_number":69,"context_line":"                                   outcome\u003d\u0027failure\u0027)"},{"line_number":70,"context_line":"                raise"},{"line_number":71,"context_line":"            else:"},{"line_number":72,"context_line":"                _send_notification(action\u003dself.cadf_action,"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xdk%3D","line":69,"updated":"2014-02-04 04:46:06.000000000","message":"suggest pulling out \u0027pending\u0027, \u0027failure\u0027 and \u0027success\u0027 somewhere else, you could enumerate them in a subclass here. \n\n  class _AuthValues(object):\n    \"\"\"CADF authentication values.\"\"\"\n    FAILURE \u003d \u0027failure\u0027\n    ... and so forth","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":66,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":67,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":68,"context_line":"                                   user_name\u003duser_name,"},{"line_number":69,"context_line":"                                   outcome\u003d\u0027failure\u0027)"},{"line_number":70,"context_line":"                raise"},{"line_number":71,"context_line":"            else:"},{"line_number":72,"context_line":"                _send_notification(action\u003dself.cadf_action,"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xV4%3D","line":69,"in_reply_to":"AAAAUH%2F9xdk%3D","updated":"2014-02-04 05:43:51.000000000","message":"Yes, you caught me being lazy :-).  These values are already defined elegantly in cadftaxonomy.py (thanks Gordon).  I will pull the values from there","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0f9a4a60a94aac1545d81335f79992d3510e76c7","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d host.Host(address\u003dremote_addr, agent\u003dhttp_user_agent)"},{"line_number":110,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":111,"context_line":"                                  name\u003duser_name,"},{"line_number":112,"context_line":"                                  host\u003dinitiator_host)"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F94EA%3D","line":109,"updated":"2014-02-02 20:14:07.000000000","message":"refactor this to \u0027pycadf_host.Host\u0027","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d host.Host(address\u003dremote_addr, agent\u003dhttp_user_agent)"},{"line_number":110,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":111,"context_line":"                                  name\u003duser_name,"},{"line_number":112,"context_line":"                                  host\u003dinitiator_host)"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xX4%3D","line":109,"in_reply_to":"AAAAUH%2F94EA%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"da42f1bbd45f0f55c495d51becf54bdee616a087","unresolved":false,"context_lines":[{"line_number":117,"context_line":"        action\u003daction,"},{"line_number":118,"context_line":"        initiator\u003dinitiator,"},{"line_number":119,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":120,"context_line":"        targetId\u003didentifier.generate_uuid())"},{"line_number":121,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":122,"context_line":"    context \u003d {}"},{"line_number":123,"context_line":"    payload \u003d event.as_dict()"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F90q4%3D","line":120,"updated":"2014-02-03 16:26:24.000000000","message":"targetId is not needed here as target and targetId values have XOR relationship. (Resource obj will generate an id attribute)\n\nwe\u0027re also missing an \u0027observer\u0027 attribute value. since it\u0027s Keystone that is reporting event, i think creating something along the lines of observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027) may work... you can also add additional Keystone descriptor values to the Resource that may be relevant.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":117,"context_line":"        action\u003daction,"},{"line_number":118,"context_line":"        initiator\u003dinitiator,"},{"line_number":119,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":120,"context_line":"        targetId\u003didentifier.generate_uuid())"},{"line_number":121,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":122,"context_line":"    context \u003d {}"},{"line_number":123,"context_line":"    payload \u003d event.as_dict()"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xX8%3D","line":120,"in_reply_to":"AAAAUH%2F90q4%3D","updated":"2014-02-04 05:43:51.000000000","message":"GREAT CATCH!!! Thanks for your CADF expertise on this!! Done!","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"39db1772d04641f8289b463fc2e6a8dce1338146","unresolved":false,"context_lines":[{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":58,"context_line":"            except Exception:"},{"line_number":59,"context_line":"                # For authentication failure send a cadf event as well"},{"line_number":60,"context_line":"                _send_notification(action\u003dself.cadf_action,"},{"line_number":61,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":62,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":63,"context_line":"                                   user_name\u003duser_name,"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAUH%2F9k5c%3D","line":60,"updated":"2014-02-05 22:40:47.000000000","message":"Is there any case this could fail in the EventFactory().new_event section or other methods in _send_notification?  If so, suggest wrapping this in a try/except as well or below expanding the try/except. otherwise ignore this comment.","commit_id":"52f897ff2351c7d493a381824e565c0770654ba6"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"5f2bdc116996bea9d071ef98e4672a78b74532bc","unresolved":false,"context_lines":[{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"},{"line_number":58,"context_line":"            except Exception:"},{"line_number":59,"context_line":"                # For authentication failure send a cadf event as well"},{"line_number":60,"context_line":"                _send_notification(action\u003dself.cadf_action,"},{"line_number":61,"context_line":"                                   remote_addr\u003dremote_addr,"},{"line_number":62,"context_line":"                                   http_user_agent\u003dhttp_user_agent,"},{"line_number":63,"context_line":"                                   user_name\u003duser_name,"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAUH%2F9jAY%3D","line":60,"in_reply_to":"AAAAUH%2F9k5c%3D","updated":"2014-02-06 05:41:16.000000000","message":"I modeled this after lbragstad\u0027s similar code so I think we are good","commit_id":"52f897ff2351c7d493a381824e565c0770654ba6"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"de8c232e1a956dbeb9c75a9fa2225e8d5c1ff007","unresolved":false,"context_lines":[{"line_number":103,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":104,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":105,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":106,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    \"\"\""},{"line_number":109,"context_line":"    initiator_host \u003d pycadf_host.Host(address\u003dremote_addr,"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAAUH%2F9xSU%3D","line":106,"updated":"2014-02-04 06:00:51.000000000","message":"Nice job commenting this.","commit_id":"52f897ff2351c7d493a381824e565c0770654ba6"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            remote_addr \u003d None"},{"line_number":40,"context_line":"            http_user_agent \u003d None"},{"line_number":41,"context_line":"            user_name \u003d None"},{"line_number":42,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027)"},{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyZY%3D","line":42,"updated":"2014-02-10 20:20:25.000000000","message":"args[1] is context, correct? the method signature of wrapper() should reflect that expectation\n\n  def wrapper(context, *args, **kwargs):\n\nthen this becomes\n\n  context.get(\u0027environment\u0027)\n\nwhich is much more self-documenting","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"32c77c6cef33da5dfdab5f04df41f93fa3fb7aa2","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            remote_addr \u003d None"},{"line_number":40,"context_line":"            http_user_agent \u003d None"},{"line_number":41,"context_line":"            user_name \u003d None"},{"line_number":42,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027)"},{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FUNo%3D","line":42,"in_reply_to":"AAAAUX%2F%2Fcqk%3D","updated":"2014-02-14 01:23:46.000000000","message":"Its not 100%. When I run with live data I get:\n2014-02-13 19:18:19.332 64843 ERROR keystone.common.wsgi [-] authenticate_for_token() takes at least 2 arguments (2 given)\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi Traceback (most recent call last):\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi   File \"/opt/stack/keystone/keystone/common/wsgi.py\", line 214, in __call__\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi     result \u003d method(context, **params)\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi   File \"/opt/stack/keystone/keystone/cadf_notifications.py\", line 55, in wrapper\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi     result \u003d f(context, *args, **kwargs)\n2014-02-13 19:18:19.332 64843 TRACE keystone.common.wsgi TypeError: authenticate_for_token() takes at least 2 arguments (2 given)","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"2ae32ff6f8ed08b4066493aac7254dd9a2611f93","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            remote_addr \u003d None"},{"line_number":40,"context_line":"            http_user_agent \u003d None"},{"line_number":41,"context_line":"            user_name \u003d None"},{"line_number":42,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027)"},{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fcqk%3D","line":42,"in_reply_to":"AAAAUX%2F%2Fvdk%3D","updated":"2014-02-13 05:56:22.000000000","message":"I was able to get something working, but i\u0027m not sure if it\u0027s 100%\n\n     def __call__(self, f):\n \n  -        def wrapper(*args, **kwargs):\n  +        def wrapper(caller, context, *args, **kwargs):\n               \"\"\"Send a notification if the wrapped callable is   successful.\"\"\"\n  -            context \u003d args[1]\n               remote_addr \u003d None\n               http_user_agent \u003d None\n               auth_identifier \u003d None\n\n  ...\n\n               try:\n  -                result \u003d f(*args, **kwargs)\n  +                result \u003d f(context, *args, **kwargs)\n               except Exception:\n                   # For authentication failure send a cadf event as well","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c8945d8cb7499579e02d2b681dcc08c5b2df9b6d","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            remote_addr \u003d None"},{"line_number":40,"context_line":"            http_user_agent \u003d None"},{"line_number":41,"context_line":"            user_name \u003d None"},{"line_number":42,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027)"},{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fxlo%3D","line":42,"in_reply_to":"AAAAUX%2F%2FyZY%3D","updated":"2014-02-10 21:41:37.000000000","message":"Done","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            remote_addr \u003d None"},{"line_number":40,"context_line":"            http_user_agent \u003d None"},{"line_number":41,"context_line":"            user_name \u003d None"},{"line_number":42,"context_line":"            environment \u003d args[1].get(\u0027environment\u0027)"},{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fvdk%3D","line":42,"in_reply_to":"AAAAUX%2F%2FyZY%3D","updated":"2014-02-11 06:55:33.000000000","message":"So I tried what you said and it did not work. I get the following error:  \nAttributeError: \u0027CadfNotificationsWrapperTestCase\u0027 object has no attribute \u0027get\u0027\n\nIt seems like what you wanted me to do is causing context to get mapped to the CadfNotificationsWrapperTestCase object instead of the context object. Did I need to make some other change to make this work????","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"78267f5d2dac9ef114710b4b248a77108f96c564","unresolved":false,"context_lines":[{"line_number":43,"context_line":"            if environment:"},{"line_number":44,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":45,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"},{"line_number":46,"context_line":"                openstack_params \u003d environment.get(\u0027openstack.params\u0027)"},{"line_number":47,"context_line":"                if openstack_params:"},{"line_number":48,"context_line":"                    auth \u003d openstack_params.get(\u0027auth\u0027)"},{"line_number":49,"context_line":"                    if auth:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyTk%3D","line":46,"updated":"2014-02-10 20:32:44.000000000","message":"If you can, please make these configurable. REMOTE_ADDR is usually the IP of the VIP if Keystone instances are HAed. Front-end proxies/VIP may use different environ/headers to convey the client information.","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":52,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":53,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":54,"context_line":"                               user_name\u003duser_name,"},{"line_number":55,"context_line":"                               outcome\u003dtaxonomy.OUTCOME_PENDING)"},{"line_number":56,"context_line":"            try:"},{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyXg%3D","line":54,"updated":"2014-02-10 20:20:25.000000000","message":"usernames are namespaced by domain","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":52,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":53,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":54,"context_line":"                               user_name\u003duser_name,"},{"line_number":55,"context_line":"                               outcome\u003dtaxonomy.OUTCOME_PENDING)"},{"line_number":56,"context_line":"            try:"},{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fuz8%3D","line":54,"in_reply_to":"AAAAUX%2F%2FxkQ%3D","updated":"2014-02-11 06:55:33.000000000","message":"I went ahead and did user_id, username + domain_name, and username +domain_id","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":52,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":53,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":54,"context_line":"                               user_name\u003duser_name,"},{"line_number":55,"context_line":"                               outcome\u003dtaxonomy.OUTCOME_PENDING)"},{"line_number":56,"context_line":"            try:"},{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fu0c%3D","line":54,"in_reply_to":"AAAAUX%2F%2FyXg%3D","updated":"2014-02-11 06:55:33.000000000","message":"Done","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c8945d8cb7499579e02d2b681dcc08c5b2df9b6d","unresolved":false,"context_lines":[{"line_number":51,"context_line":"            _send_notification(action\u003dself.cadf_action,"},{"line_number":52,"context_line":"                               remote_addr\u003dremote_addr,"},{"line_number":53,"context_line":"                               http_user_agent\u003dhttp_user_agent,"},{"line_number":54,"context_line":"                               user_name\u003duser_name,"},{"line_number":55,"context_line":"                               outcome\u003dtaxonomy.OUTCOME_PENDING)"},{"line_number":56,"context_line":"            try:"},{"line_number":57,"context_line":"                result \u003d f(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FxkQ%3D","line":54,"in_reply_to":"AAAAUX%2F%2FyXg%3D","updated":"2014-02-10 21:41:37.000000000","message":"lets change this to just get user_id....\n\nwe can deal with the combo of \nuser_name + domain_id || user_name + domain_name || user_name (v2) later on. \n\nuser_id is easiest","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    return CadfNotificationWrapper(*args, **kwargs)"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def _get_user_name_from_auth(auth):"},{"line_number":83,"context_line":"    user_name \u003d None"},{"line_number":84,"context_line":"    # First try V2 auth structure."},{"line_number":85,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyYE%3D","line":82,"updated":"2014-02-10 20:20:25.000000000","message":"there isn\u0027t always a username in auth","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    return CadfNotificationWrapper(*args, **kwargs)"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def _get_user_name_from_auth(auth):"},{"line_number":83,"context_line":"    user_name \u003d None"},{"line_number":84,"context_line":"    # First try V2 auth structure."},{"line_number":85,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fuzs%3D","line":82,"in_reply_to":"AAAAUX%2F%2Fxj4%3D","updated":"2014-02-11 06:55:33.000000000","message":"Done","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    return CadfNotificationWrapper(*args, **kwargs)"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def _get_user_name_from_auth(auth):"},{"line_number":83,"context_line":"    user_name \u003d None"},{"line_number":84,"context_line":"    # First try V2 auth structure."},{"line_number":85,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fuzw%3D","line":82,"in_reply_to":"AAAAUX%2F%2FyYE%3D","updated":"2014-02-11 06:55:33.000000000","message":"I now handle the other cases as well","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c8945d8cb7499579e02d2b681dcc08c5b2df9b6d","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    return CadfNotificationWrapper(*args, **kwargs)"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"def _get_user_name_from_auth(auth):"},{"line_number":83,"context_line":"    user_name \u003d None"},{"line_number":84,"context_line":"    # First try V2 auth structure."},{"line_number":85,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2Fxj4%3D","line":82,"in_reply_to":"AAAAUX%2F%2FyYE%3D","updated":"2014-02-10 21:41:37.000000000","message":"Same as before, lets just get user_id, and make this function more generic sounding.... like _get_audit_info?","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"21d0cd9ad16cbd5babf7b7a32c229291b0e69c00","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        try:"},{"line_number":90,"context_line":"            user_name \u003d auth[\u0027identity\u0027][\u0027password\u0027][\u0027user\u0027][\u0027name\u0027]"},{"line_number":91,"context_line":"        except KeyError:"},{"line_number":92,"context_line":"            pass"},{"line_number":93,"context_line":"    return user_name"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2F8No%3D","line":92,"updated":"2014-02-09 05:19:34.000000000","message":"Couldn\u0027t we log some information here saying no v2 or v3 auth structure was detected?","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        try:"},{"line_number":90,"context_line":"            user_name \u003d auth[\u0027identity\u0027][\u0027password\u0027][\u0027user\u0027][\u0027name\u0027]"},{"line_number":91,"context_line":"        except KeyError:"},{"line_number":92,"context_line":"            pass"},{"line_number":93,"context_line":"    return user_name"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FuwM%3D","line":92,"in_reply_to":"AAAAUX%2F%2F8No%3D","updated":"2014-02-11 06:55:33.000000000","message":"Done","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        try:"},{"line_number":90,"context_line":"            user_name \u003d auth[\u0027identity\u0027][\u0027password\u0027][\u0027user\u0027][\u0027name\u0027]"},{"line_number":91,"context_line":"        except KeyError:"},{"line_number":92,"context_line":"            pass"},{"line_number":93,"context_line":"    return user_name"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyYw%3D","line":92,"in_reply_to":"AAAAUX%2F%2F8No%3D","updated":"2014-02-10 20:20:25.000000000","message":"this will break if i authenticate by user ID\n\nor if i rescope a token (not sure this code should care about that scenario though?)","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":89,"context_line":"        try:"},{"line_number":90,"context_line":"            user_name \u003d auth[\u0027identity\u0027][\u0027password\u0027][\u0027user\u0027][\u0027name\u0027]"},{"line_number":91,"context_line":"        except KeyError:"},{"line_number":92,"context_line":"            pass"},{"line_number":93,"context_line":"    return user_name"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FuyY%3D","line":92,"in_reply_to":"AAAAUX%2F%2FyYw%3D","updated":"2014-02-11 06:55:33.000000000","message":"authenticate by user Id is now fixed","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"cb88f2eeeaabaf5ea65e66f6b356a69d3bd09c11","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":121,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":122,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":123,"context_line":"    context \u003d {}"},{"line_number":124,"context_line":"    payload \u003d event.as_dict()"},{"line_number":125,"context_line":"    service \u003d \u0027identity\u0027"},{"line_number":126,"context_line":"    publisher_id \u003d notifier_api.publisher_id(service)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FyXk%3D","line":123,"updated":"2014-02-10 20:20:25.000000000","message":"this makes me wonder what notify() expects to do with \u0027context\u0027","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"6a1d04dcadb23af42ff2a0f8da02175eb29d543f","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":121,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":122,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":123,"context_line":"    context \u003d {}"},{"line_number":124,"context_line":"    payload \u003d event.as_dict()"},{"line_number":125,"context_line":"    service \u003d \u0027identity\u0027"},{"line_number":126,"context_line":"    publisher_id \u003d notifier_api.publisher_id(service)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FuyE%3D","line":123,"in_reply_to":"AAAAUX%2F%2FxjQ%3D","updated":"2014-02-11 06:55:33.000000000","message":"I think Lance told me context isnt used for anything","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c8945d8cb7499579e02d2b681dcc08c5b2df9b6d","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":121,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":122,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":123,"context_line":"    context \u003d {}"},{"line_number":124,"context_line":"    payload \u003d event.as_dict()"},{"line_number":125,"context_line":"    service \u003d \u0027identity\u0027"},{"line_number":126,"context_line":"    publisher_id \u003d notifier_api.publisher_id(service)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAAUX%2F%2FxjQ%3D","line":123,"in_reply_to":"AAAAUX%2F%2FyXk%3D","updated":"2014-02-10 21:41:37.000000000","message":"With your suggestion to the CADF wrapper, we could pass in context to _send_notification, and pass it to notify() ?","commit_id":"8b17fbb75ccfeeaf1ce147ac3c232f51764877c9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"db51bb91963a3892ef25163f50880ebf49f81d81","unresolved":false,"context_lines":[{"line_number":121,"context_line":"            user_name \u003d _lookup(auth, \u0027identity\u0027, \u0027password\u0027, \u0027user\u0027, \u0027name\u0027)"},{"line_number":122,"context_line":"            if user_name:"},{"line_number":123,"context_line":"                #Need a domain name or a domain id when using user_name"},{"line_number":124,"context_line":"                domain_name \u003d _lookup(auth, \u0027identity\u0027, \u0027password\u0027, \u0027user\u0027,"},{"line_number":125,"context_line":"                                      \u0027domain\u0027, \u0027name\u0027)"},{"line_number":126,"context_line":"                if domain_name:"},{"line_number":127,"context_line":"                    #If we have user_name and domain_name we are done"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAAUX%2F%2FudY%3D","line":124,"updated":"2014-02-11 07:49:07.000000000","message":"neat!","commit_id":"404f0c4e7d1cad78b3d1f0e33ca2ca3f998fbbe1"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# vim: tabstop\u003d4 shiftwidth\u003d4 softtabstop\u003d4"},{"line_number":2,"context_line":"#"},{"line_number":3,"context_line":"#   Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":4,"context_line":"#   not use this file except in compliance with the License. You may obtain"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FceI%3D","line":1,"updated":"2014-02-13 06:23:42.000000000","message":"remove these first 2 lines, as all files in keystone just got rid of them.","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"0f4eb04c19b02d0f8a0d58a39d4c1946fbf4409e","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":38,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":39,"context_line":"            context \u003d args[1]"},{"line_number":40,"context_line":"            remote_addr \u003d None"},{"line_number":41,"context_line":"            http_user_agent \u003d None"},{"line_number":42,"context_line":"            auth_identifier \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FpLc%3D","line":39,"updated":"2014-02-11 19:40:19.000000000","message":"dolph, this was the best I could come up with regarding your request.  None of the wrapper signature changes that you suggested worked for me.  Feel free to school me on this :-)","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"7581eb81f52a6415cfbf6fbe0337ce44cdf1a4d2","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":38,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":39,"context_line":"            context \u003d args[1]"},{"line_number":40,"context_line":"            remote_addr \u003d None"},{"line_number":41,"context_line":"            http_user_agent \u003d None"},{"line_number":42,"context_line":"            auth_identifier \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FUL4%3D","line":39,"in_reply_to":"AAAAUX%2F%2Fcd4%3D","updated":"2014-02-14 01:30:15.000000000","message":"It doesn\u0027t work for live data when I run curl invocations. I put the stack trace in patch 9.","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":38,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":39,"context_line":"            context \u003d args[1]"},{"line_number":40,"context_line":"            remote_addr \u003d None"},{"line_number":41,"context_line":"            http_user_agent \u003d None"},{"line_number":42,"context_line":"            auth_identifier \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2Fcd4%3D","line":39,"in_reply_to":"AAAAUX%2F%2Feas%3D","updated":"2014-02-13 06:23:42.000000000","message":"i replied to patch 9 with some more details on what I got to (kinda) work, @dolphm - please look it over","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c7df0bd4fec4337b0d34b9eee701ff41fdd0d1fd","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"        def wrapper(*args, **kwargs):"},{"line_number":38,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":39,"context_line":"            context \u003d args[1]"},{"line_number":40,"context_line":"            remote_addr \u003d None"},{"line_number":41,"context_line":"            http_user_agent \u003d None"},{"line_number":42,"context_line":"            auth_identifier \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2Feas%3D","line":39,"in_reply_to":"AAAAUX%2F%2FpLc%3D","updated":"2014-02-13 05:31:26.000000000","message":"Brad, I think Dolph was asking for something like this: \nhttps://review.openstack.org/#/c/72716/1/keystone/common/sql/core.py","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":90,"context_line":"    \"\"\"Try and get some form of auth identifier"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    Auth identifier could be a username plus domain name or domain id"},{"line_number":93,"context_line":"    or it could be a user_id"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"    \"\"\""},{"line_number":96,"context_line":"    user_name \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2Fcdc%3D","line":93,"updated":"2014-02-13 06:23:42.000000000","message":"(nit) add a period","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"7581eb81f52a6415cfbf6fbe0337ce44cdf1a4d2","unresolved":false,"context_lines":[{"line_number":90,"context_line":"    \"\"\"Try and get some form of auth identifier"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    Auth identifier could be a username plus domain name or domain id"},{"line_number":93,"context_line":"    or it could be a user_id"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"    \"\"\""},{"line_number":96,"context_line":"    user_name \u003d None"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FUL0%3D","line":93,"in_reply_to":"AAAAUX%2F%2Fcdc%3D","updated":"2014-02-14 01:30:15.000000000","message":"Done","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":100,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"},{"line_number":101,"context_line":"        user_name \u003d _lookup(auth, \u0027passwordCredentials\u0027, \u0027username\u0027)"},{"line_number":102,"context_line":"        if user_name:"},{"line_number":103,"context_line":"            #For V2 username is all we need"},{"line_number":104,"context_line":"            return user_name"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            #If no username check for user_id"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2Fcds%3D","line":103,"updated":"2014-02-13 06:23:42.000000000","message":"(nit) space between # and comment, this entire method","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"7581eb81f52a6415cfbf6fbe0337ce44cdf1a4d2","unresolved":false,"context_lines":[{"line_number":100,"context_line":"    if \u0027passwordCredentials\u0027 in auth:"},{"line_number":101,"context_line":"        user_name \u003d _lookup(auth, \u0027passwordCredentials\u0027, \u0027username\u0027)"},{"line_number":102,"context_line":"        if user_name:"},{"line_number":103,"context_line":"            #For V2 username is all we need"},{"line_number":104,"context_line":"            return user_name"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            #If no username check for user_id"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FULw%3D","line":103,"in_reply_to":"AAAAUX%2F%2Fcds%3D","updated":"2014-02-14 01:30:15.000000000","message":"Done","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        #If we get here just return user_name even if None"},{"line_number":111,"context_line":"        return user_name"},{"line_number":112,"context_line":"    #  Otherwise see if we have a V3 auth structure"},{"line_number":113,"context_line":"    elif \u0027identity\u0027 in auth:"},{"line_number":114,"context_line":"        #Check if a user_id exists"},{"line_number":115,"context_line":"        user_id \u003d _lookup(auth, \u0027identity\u0027, \u0027password\u0027, \u0027user\u0027, \u0027id\u0027)"},{"line_number":116,"context_line":"        if user_id:"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2Fccg%3D","line":113,"updated":"2014-02-13 06:23:42.000000000","message":"nit: you have an elif without an else, suggest add an else block to line 135 ish","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"7581eb81f52a6415cfbf6fbe0337ce44cdf1a4d2","unresolved":false,"context_lines":[{"line_number":110,"context_line":"        #If we get here just return user_name even if None"},{"line_number":111,"context_line":"        return user_name"},{"line_number":112,"context_line":"    #  Otherwise see if we have a V3 auth structure"},{"line_number":113,"context_line":"    elif \u0027identity\u0027 in auth:"},{"line_number":114,"context_line":"        #Check if a user_id exists"},{"line_number":115,"context_line":"        user_id \u003d _lookup(auth, \u0027identity\u0027, \u0027password\u0027, \u0027user\u0027, \u0027id\u0027)"},{"line_number":116,"context_line":"        if user_id:"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FULs%3D","line":113,"in_reply_to":"AAAAUX%2F%2Fccg%3D","updated":"2014-02-14 01:30:15.000000000","message":"Done","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"8fdd142abff111f2897de229e3959faaa2ae0d49","unresolved":false,"context_lines":[{"line_number":137,"context_line":"    return user_name"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"def _send_audit_notification(action, remote_addr, http_user_agent, user_name,"},{"line_number":141,"context_line":"                             outcome):"},{"line_number":142,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":143,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FccE%3D","line":140,"updated":"2014-02-13 06:23:42.000000000","message":"if we do end up getting the context from the auth methods, then it should be passed in, and used, instead of setting it to {} at line 167.","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"0d643b968281e7c939e99914c904432b1108913e","unresolved":false,"context_lines":[{"line_number":137,"context_line":"    return user_name"},{"line_number":138,"context_line":""},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"def _send_audit_notification(action, remote_addr, http_user_agent, user_name,"},{"line_number":141,"context_line":"                             outcome):"},{"line_number":142,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":143,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAAUX%2F%2FUSw%3D","line":140,"in_reply_to":"AAAAUX%2F%2FccE%3D","updated":"2014-02-14 01:04:20.000000000","message":"context is overloaded. The  keystone context is different than the event context.  From what I have been told the event context should just be {}","commit_id":"918d6bda83938c5714032ae4230b88d66e31dab9"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"eb8254f735ca77d52df2d1ba32059cd88ea5dc4d","unresolved":false,"context_lines":[{"line_number":51,"context_line":"                _send_audit_notification(action\u003dself.cadf_action,"},{"line_number":52,"context_line":"                                         remote_addr\u003dremote_addr,"},{"line_number":53,"context_line":"                                         http_user_agent\u003dhttp_user_agent,"},{"line_number":54,"context_line":"                                         user_name\u003duser_id,"},{"line_number":55,"context_line":"                                         outcome\u003dtaxonomy.OUTCOME_FAILURE)"},{"line_number":56,"context_line":"                raise"},{"line_number":57,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAUX%2F%2FMuI%3D","line":54,"updated":"2014-02-14 23:21:12.000000000","message":"i\u0027m  being picky here, but lets just use user_id\u003duser_id. keeps things consistent","commit_id":"4af2e61083c9891b3a49666c8abced0b8fd7851b"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":12,"context_line":""},{"line_number":13,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":14,"context_line":"from pycadf import eventfactory"},{"line_number":15,"context_line":"from pycadf import host as pycadf_host"},{"line_number":16,"context_line":"from pycadf import resource"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.openstack.common import log"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIgU%3D","line":15,"updated":"2014-02-16 16:37:50.000000000","message":"Can we use \"import pycadf\" here and \"pycadf.host\" in the code instead?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":12,"context_line":""},{"line_number":13,"context_line":"from pycadf import cadftaxonomy as taxonomy"},{"line_number":14,"context_line":"from pycadf import eventfactory"},{"line_number":15,"context_line":"from pycadf import host as pycadf_host"},{"line_number":16,"context_line":"from pycadf import resource"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.openstack.common import log"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIQM%3D","line":15,"in_reply_to":"AAAAUX%2F%2FIgU%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":16,"context_line":"from pycadf import resource"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.openstack.common import log"},{"line_number":19,"context_line":"from keystone.openstack.common.notifier import api as notifier_api"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIeg%3D","line":19,"updated":"2014-02-16 16:37:50.000000000","message":"Note that with https://review.openstack.org/#/c/70664/ this is going away.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":16,"context_line":"from pycadf import resource"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.openstack.common import log"},{"line_number":19,"context_line":"from keystone.openstack.common.notifier import api as notifier_api"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FILs%3D","line":19,"in_reply_to":"AAAAUX%2F%2FIeg%3D","updated":"2014-02-16 18:53:05.000000000","message":"ugh... i\u0027ll rebase this when/if it lands.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    successful or not."},{"line_number":29,"context_line":"    \"\"\""},{"line_number":30,"context_line":"    def __init__(self, action):"},{"line_number":31,"context_line":"        self.cadf_action \u003d action"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIgM%3D","line":31,"updated":"2014-02-16 16:37:50.000000000","message":"suggest remove \"cadf_\" prefix since that\u0027s the name of the class anyways.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    successful or not."},{"line_number":29,"context_line":"    \"\"\""},{"line_number":30,"context_line":"    def __init__(self, action):"},{"line_number":31,"context_line":"        self.cadf_action \u003d action"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIQI%3D","line":31,"in_reply_to":"AAAAUX%2F%2FIgM%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":31,"context_line":"        self.cadf_action \u003d action"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"},{"line_number":35,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":36,"context_line":"            remote_addr \u003d None"},{"line_number":37,"context_line":"            http_user_agent \u003d None"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIgE%3D","line":34,"updated":"2014-02-16 16:37:50.000000000","message":"use functools.wraps -- http://docs.python.org/2/library/functools.html#functools.wraps","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":31,"context_line":"        self.cadf_action \u003d action"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"},{"line_number":35,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":36,"context_line":"            remote_addr \u003d None"},{"line_number":37,"context_line":"            http_user_agent \u003d None"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIJI%3D","line":34,"in_reply_to":"AAAAUX%2F%2FIgE%3D","updated":"2014-02-16 18:53:05.000000000","message":"I stuck to this format because its used in the other notifications class, i\u0027ll start looking into this, but i\u0027ll post all the other changes.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"},{"line_number":35,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":36,"context_line":"            remote_addr \u003d None"},{"line_number":37,"context_line":"            http_user_agent \u003d None"},{"line_number":38,"context_line":"            environment \u003d context.get(\u0027environment\u0027)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIgA%3D","line":35,"updated":"2014-02-16 16:37:50.000000000","message":"this documentation isn\u0027t accurate since a notification is sent even if it\u0027s not successful.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def __call__(self, f):"},{"line_number":34,"context_line":"        def wrapper(wrapped_self, context, user_id, *args, **kwargs):"},{"line_number":35,"context_line":"            \"\"\"Send a notification if the wrapped callable is successful.\"\"\""},{"line_number":36,"context_line":"            remote_addr \u003d None"},{"line_number":37,"context_line":"            http_user_agent \u003d None"},{"line_number":38,"context_line":"            environment \u003d context.get(\u0027environment\u0027)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIO8%3D","line":35,"in_reply_to":"AAAAUX%2F%2FIgA%3D","updated":"2014-02-16 18:53:05.000000000","message":"I changed it to \"Always send a notification\"","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            if environment:"},{"line_number":40,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":41,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"},{"line_number":42,"context_line":"            _send_audit_notification(action\u003dself.cadf_action,"},{"line_number":43,"context_line":"                                     remote_addr\u003dremote_addr,"},{"line_number":44,"context_line":"                                     http_user_agent\u003dhttp_user_agent,"},{"line_number":45,"context_line":"                                     user_id\u003duser_id,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIf8%3D","line":42,"updated":"2014-02-16 16:37:50.000000000","message":"suggest remove action\u003d, remote_addr\u003d, etc., since the variables are named well and _send_audit_notification takes positional args. (applies at 51 \u0026 58 too)","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":39,"context_line":"            if environment:"},{"line_number":40,"context_line":"                remote_addr \u003d environment.get(\u0027REMOTE_ADDR\u0027)"},{"line_number":41,"context_line":"                http_user_agent \u003d environment.get(\u0027HTTP_USER_AGENT\u0027)"},{"line_number":42,"context_line":"            _send_audit_notification(action\u003dself.cadf_action,"},{"line_number":43,"context_line":"                                     remote_addr\u003dremote_addr,"},{"line_number":44,"context_line":"                                     http_user_agent\u003dhttp_user_agent,"},{"line_number":45,"context_line":"                                     user_id\u003duser_id,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIOM%3D","line":42,"in_reply_to":"AAAAUX%2F%2FIf8%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                                         http_user_agent\u003dhttp_user_agent,"},{"line_number":61,"context_line":"                                         user_id\u003duser_id,"},{"line_number":62,"context_line":"                                         outcome\u003dtaxonomy.OUTCOME_SUCCESS)"},{"line_number":63,"context_line":"            return result"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"        return wrapper"},{"line_number":66,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfw%3D","line":63,"updated":"2014-02-16 16:37:50.000000000","message":"suggest put \"return result\" in with the else: leg. The way it is now, it looks like there\u0027s some case where the _send_audit_notification(OUTCOME_SUCCESS) might not happen while \"return result\" does, but that can\u0027t happen. So make the code reflect how it actually works.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":60,"context_line":"                                         http_user_agent\u003dhttp_user_agent,"},{"line_number":61,"context_line":"                                         user_id\u003duser_id,"},{"line_number":62,"context_line":"                                         outcome\u003dtaxonomy.OUTCOME_SUCCESS)"},{"line_number":63,"context_line":"            return result"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"        return wrapper"},{"line_number":66,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIOk%3D","line":63,"in_reply_to":"AAAAUX%2F%2FIfw%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":67,"context_line":""},{"line_number":68,"context_line":"def emit_event(action):"},{"line_number":69,"context_line":"    \"\"\"Decorator to send notifications for Authenticate methods.\"\"\""},{"line_number":70,"context_line":"    return CadfNotificationWrapper(action)"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"def _send_audit_notification(action, remote_addr, http_user_agent, user_id,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfg%3D","line":70,"updated":"2014-02-16 16:37:50.000000000","message":"isn\u0027t 68-70 just\n\nemit_event \u003d CadfNotificationWrapper\n\n?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":67,"context_line":""},{"line_number":68,"context_line":"def emit_event(action):"},{"line_number":69,"context_line":"    \"\"\"Decorator to send notifications for Authenticate methods.\"\"\""},{"line_number":70,"context_line":"    return CadfNotificationWrapper(action)"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"def _send_audit_notification(action, remote_addr, http_user_agent, user_id,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FINQ%3D","line":70,"in_reply_to":"AAAAUX%2F%2FIfg%3D","updated":"2014-02-16 18:53:05.000000000","message":"yeah, it looked funny that way, I added \nemit_event \u003d CadfNotificationWrapper to the end of file, and removed these lines","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfU%3D","line":79,"updated":"2014-02-16 16:37:50.000000000","message":"suggest change \"authenticate\" to \"e.g., \u0027authenticate\u0027\" ?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIMo%3D","line":79,"in_reply_to":"AAAAUX%2F%2FIfU%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfQ%3D","line":80,"updated":"2014-02-16 16:37:50.000000000","message":"what if the action isn\u0027t authentication?\n\nAlso, suggest add \"may be None\"","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":77,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIMk%3D","line":80,"in_reply_to":"AAAAUX%2F%2FIfQ%3D","updated":"2014-02-16 18:53:05.000000000","message":"changed to: The IP address of the requesting client, may be None","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfM%3D","line":81,"updated":"2014-02-16 16:37:50.000000000","message":"what if the action isn\u0027t authentication?\n\nAlso, suggest add \"may be None\"","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIMg%3D","line":81,"in_reply_to":"AAAAUX%2F%2FIfM%3D","updated":"2014-02-16 18:53:05.000000000","message":"changed to HTTP user agent from the request, may be None","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfE%3D","line":82,"updated":"2014-02-16 16:37:50.000000000","message":"what if it isn\u0027t an authentication request?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    :param action: CADF action being audited (authenticate)"},{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIMc%3D","line":82,"in_reply_to":"AAAAUX%2F%2FIfE%3D","updated":"2014-02-16 18:53:05.000000000","message":"The user name sent in with the request","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""},{"line_number":86,"context_line":"    initiator_host \u003d pycadf_host.Host(address\u003dremote_addr,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfY%3D","line":83,"updated":"2014-02-16 16:37:50.000000000","message":"suggest use taxonomy.OUTCOME_SUCCESS rather than \"pending, success, failure\" -- would be nice to be able to refer to some enumerated type but it looks like pycadf didn\u0027t do that.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":80,"context_line":"    :param remote_addr: the IP address of the client requesting authentication"},{"line_number":81,"context_line":"    :param http_user_agent: HTTP user agent from the authentication request"},{"line_number":82,"context_line":"    :param user_name: the user name sent in with the authentication request"},{"line_number":83,"context_line":"    :param outcome: the CADF outcome (pending, success, failure)"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""},{"line_number":86,"context_line":"    initiator_host \u003d pycadf_host.Host(address\u003dremote_addr,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIMU%3D","line":83,"in_reply_to":"AAAAUX%2F%2FIfY%3D","updated":"2014-02-16 18:53:05.000000000","message":"changed to:\n  :param outcome: The CADF outcome (taxonomy.OUTCOME_PENDING,\n        taxonomy.OUTCOME_SUCCESS, taxonomy.OUTCOME_FAILURE)","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""},{"line_number":86,"context_line":"    initiator_host \u003d pycadf_host.Host(address\u003dremote_addr,"},{"line_number":87,"context_line":"                                      agent\u003dhttp_user_agent)"},{"line_number":88,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":89,"context_line":"                                  name\u003duser_id,"},{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIfA%3D","line":87,"updated":"2014-02-16 16:37:50.000000000","message":"suggest pass in a pycadf_host.Host to this function rather than remote_addr and http_user_agent.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    \"\"\""},{"line_number":86,"context_line":"    initiator_host \u003d pycadf_host.Host(address\u003dremote_addr,"},{"line_number":87,"context_line":"                                      agent\u003dhttp_user_agent)"},{"line_number":88,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":89,"context_line":"                                  name\u003duser_id,"},{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIJY%3D","line":87,"in_reply_to":"AAAAUX%2F%2FIfA%3D","updated":"2014-02-16 18:53:05.000000000","message":"good idea!","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":87,"context_line":"                                      agent\u003dhttp_user_agent)"},{"line_number":88,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":89,"context_line":"                                  name\u003duser_id,"},{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    event \u003d eventfactory.EventFactory().new_event("},{"line_number":93,"context_line":"        eventType\u003d\u0027activity\u0027,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIe8%3D","line":90,"updated":"2014-02-16 16:37:50.000000000","message":"suggest pass in a resource.Resource to this function rather than user_id and pycadf_host.Host.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":87,"context_line":"                                      agent\u003dhttp_user_agent)"},{"line_number":88,"context_line":"    initiator \u003d resource.Resource(typeURI\u003dtaxonomy.ACCOUNT_USER,"},{"line_number":89,"context_line":"                                  name\u003duser_id,"},{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    event \u003d eventfactory.EventFactory().new_event("},{"line_number":93,"context_line":"        eventType\u003d\u0027activity\u0027,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIJU%3D","line":90,"in_reply_to":"AAAAUX%2F%2FIe8%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    event \u003d eventfactory.EventFactory().new_event("},{"line_number":93,"context_line":"        eventType\u003d\u0027activity\u0027,"},{"line_number":94,"context_line":"        outcome\u003doutcome,"},{"line_number":95,"context_line":"        action\u003daction,"},{"line_number":96,"context_line":"        initiator\u003dinitiator,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIe4%3D","line":93,"updated":"2014-02-16 16:37:50.000000000","message":"where does the \u0027activity\u0027 magic number come from?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":90,"context_line":"                                  host\u003dinitiator_host)"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    event \u003d eventfactory.EventFactory().new_event("},{"line_number":93,"context_line":"        eventType\u003d\u0027activity\u0027,"},{"line_number":94,"context_line":"        outcome\u003doutcome,"},{"line_number":95,"context_line":"        action\u003daction,"},{"line_number":96,"context_line":"        initiator\u003dinitiator,"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIKc%3D","line":93,"in_reply_to":"AAAAUX%2F%2FIe4%3D","updated":"2014-02-16 18:53:05.000000000","message":"from cadftype.EVENTTYPE_ACTIVITY of course","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        outcome\u003doutcome,"},{"line_number":95,"context_line":"        action\u003daction,"},{"line_number":96,"context_line":"        initiator\u003dinitiator,"},{"line_number":97,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":98,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":99,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":100,"context_line":"    context \u003d {}"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIew%3D","line":97,"updated":"2014-02-16 16:37:50.000000000","message":"where do these magic numbers come from?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":94,"context_line":"        outcome\u003doutcome,"},{"line_number":95,"context_line":"        action\u003daction,"},{"line_number":96,"context_line":"        initiator\u003dinitiator,"},{"line_number":97,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":98,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":99,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":100,"context_line":"    context \u003d {}"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIKE%3D","line":97,"in_reply_to":"AAAAUX%2F%2FIew%3D","updated":"2014-02-16 18:53:05.000000000","message":"the first come from taxonomy.ACCOUNT_USER and the second is also defined in taxonomy, but part of a set...","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        initiator\u003dinitiator,"},{"line_number":97,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":98,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":99,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":100,"context_line":"    context \u003d {}"},{"line_number":101,"context_line":"    payload \u003d event.as_dict()"},{"line_number":102,"context_line":"    service \u003d \u0027identity\u0027"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIes%3D","line":99,"updated":"2014-02-16 16:37:50.000000000","message":"suggest remove \"Keystone\" since that\u0027s in the log info already.\n\nalso, suggest do event.as_dict() once rather than here and at line 101.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        initiator\u003dinitiator,"},{"line_number":97,"context_line":"        target\u003dresource.Resource(typeURI\u003d\u0027service/security/account/user\u0027),"},{"line_number":98,"context_line":"        observer\u003dresource.Resource(typeURI\u003d\u0027service/security\u0027))"},{"line_number":99,"context_line":"    LOG.debug(_(\u0027Keystone CADF Event: %s\u0027), event.as_dict())"},{"line_number":100,"context_line":"    context \u003d {}"},{"line_number":101,"context_line":"    payload \u003d event.as_dict()"},{"line_number":102,"context_line":"    service \u003d \u0027identity\u0027"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIQo%3D","line":99,"in_reply_to":"AAAAUX%2F%2FIes%3D","updated":"2014-02-16 18:53:05.000000000","message":"1st remark - Done\n2nd remark - I just moved the log line down by 2.. and just pass in payload.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":100,"context_line":"    context \u003d {}"},{"line_number":101,"context_line":"    payload \u003d event.as_dict()"},{"line_number":102,"context_line":"    service \u003d \u0027identity\u0027"},{"line_number":103,"context_line":"    publisher_id \u003d notifier_api.publisher_id(service)"},{"line_number":104,"context_line":"    event_type \u003d \u0027%(service)s.%(action)s\u0027 % {\u0027service\u0027: service,"},{"line_number":105,"context_line":"                                             \u0027action\u0027: action}"},{"line_number":106,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIek%3D","line":103,"updated":"2014-02-16 16:37:50.000000000","message":"is this ever going to change? if not, suggest save it somewhere so only do it once.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":100,"context_line":"    context \u003d {}"},{"line_number":101,"context_line":"    payload \u003d event.as_dict()"},{"line_number":102,"context_line":"    service \u003d \u0027identity\u0027"},{"line_number":103,"context_line":"    publisher_id \u003d notifier_api.publisher_id(service)"},{"line_number":104,"context_line":"    event_type \u003d \u0027%(service)s.%(action)s\u0027 % {\u0027service\u0027: service,"},{"line_number":105,"context_line":"                                             \u0027action\u0027: action}"},{"line_number":106,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FILA%3D","line":103,"in_reply_to":"AAAAUX%2F%2FIek%3D","updated":"2014-02-16 18:53:05.000000000","message":"this will be removed when the patch to change to oslo lands anyway.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        notifier_api.notify("},{"line_number":109,"context_line":"            context, publisher_id, event_type, notifier_api.INFO, payload)"},{"line_number":110,"context_line":"    except Exception:"},{"line_number":111,"context_line":"        LOG.exception("},{"line_number":112,"context_line":"            _(\u0027Failed to send %(action)s %(event_type)s notification\u0027),"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIdo%3D","line":109,"updated":"2014-02-16 16:37:50.000000000","message":"since the \"INFO\" constant is so poorly named, suggest use a keyword argument so that readers know what it\u0027s for: priority\u003dnotifier_api.INFO","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    try:"},{"line_number":108,"context_line":"        notifier_api.notify("},{"line_number":109,"context_line":"            context, publisher_id, event_type, notifier_api.INFO, payload)"},{"line_number":110,"context_line":"    except Exception:"},{"line_number":111,"context_line":"        LOG.exception("},{"line_number":112,"context_line":"            _(\u0027Failed to send %(action)s %(event_type)s notification\u0027),"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FILI%3D","line":109,"in_reply_to":"AAAAUX%2F%2FIdo%3D","updated":"2014-02-16 18:53:05.000000000","message":"it\u0027ll be going away when the patch to change to oslo lands anyway.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":108,"context_line":"        notifier_api.notify("},{"line_number":109,"context_line":"            context, publisher_id, event_type, notifier_api.INFO, payload)"},{"line_number":110,"context_line":"    except Exception:"},{"line_number":111,"context_line":"        LOG.exception("},{"line_number":112,"context_line":"            _(\u0027Failed to send %(action)s %(event_type)s notification\u0027),"},{"line_number":113,"context_line":"            {\u0027action\u0027: action, \u0027event_type\u0027: event_type})"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIbY%3D","line":111,"updated":"2014-02-16 16:37:50.000000000","message":"there should be a unit test that covers this case.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"}],"keystone/notifications.py":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"bc3510082430ef176ed8b8df5e26b1f90a92c84d","unresolved":false,"context_lines":[{"line_number":268,"context_line":"def _send_audit_notification(action, initiator, outcome):"},{"line_number":269,"context_line":"    \"\"\"Send CADF notification to inform observers about the affected resource."},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"    This method doesn\u0027t raise an exception when sending the notification fails."},{"line_number":272,"context_line":""},{"line_number":273,"context_line":"    :param action: CADF action being audited (e.g., \u0027authenticate\u0027)"},{"line_number":274,"context_line":"    :param initiator: CADF resource representing the initiator"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUX%2F%2B8Ek%3D","line":271,"updated":"2014-02-18 04:11:44.000000000","message":"If this gets respun, could just say in addition to this comment that instead the exception is logged. But that is super nit picky.","commit_id":"c94164a8edce533226e50b06bc4a0c7bed343529"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"b40c65c16b3e0cefae1f129833fcf5fcfe7edbb3","unresolved":false,"context_lines":[{"line_number":292,"context_line":"                                             \u0027action\u0027: action}"},{"line_number":293,"context_line":""},{"line_number":294,"context_line":"    notifier \u003d _get_notifier()"},{"line_number":295,"context_line":"    msg_data \u003d {\u0027action\u0027: action, \u0027event_type\u0027: event_type}"},{"line_number":296,"context_line":""},{"line_number":297,"context_line":"    if notifier:"},{"line_number":298,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":23,"id":"AAAAUX%2F%2B3Xs%3D","line":295,"updated":"2014-02-18 15:09:31.000000000","message":"(nit) I would probably move this into the except block since that\u0027s the only place it is used.","commit_id":"46c72279a629a6d0f51869460ea977c0afcc824a"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"80ab90eda19681e2dd685c1ad6f80581cc173958","unresolved":false,"context_lines":[{"line_number":292,"context_line":"                                             \u0027action\u0027: action}"},{"line_number":293,"context_line":""},{"line_number":294,"context_line":"    notifier \u003d _get_notifier()"},{"line_number":295,"context_line":"    msg_data \u003d {\u0027action\u0027: action, \u0027event_type\u0027: event_type}"},{"line_number":296,"context_line":""},{"line_number":297,"context_line":"    if notifier:"},{"line_number":298,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":23,"id":"AAAAUX%2F%2B3A0%3D","line":295,"in_reply_to":"AAAAUX%2F%2B3Xs%3D","updated":"2014-02-18 15:17:54.000000000","message":"++ i thought i did that, actually","commit_id":"46c72279a629a6d0f51869460ea977c0afcc824a"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"b40c65c16b3e0cefae1f129833fcf5fcfe7edbb3","unresolved":false,"context_lines":[{"line_number":297,"context_line":"    if notifier:"},{"line_number":298,"context_line":"        try:"},{"line_number":299,"context_line":"            notifier.info(context, event_type, payload)"},{"line_number":300,"context_line":"        except Exception:"},{"line_number":301,"context_line":"            LOG.exception(_(\u0027Failed to send %(action)s %(event_type)s\u0027"},{"line_number":302,"context_line":"                            \u0027 notification\u0027), msg_data)"},{"line_number":303,"context_line":""}],"source_content_type":"text/x-python","patch_set":23,"id":"AAAAUX%2F%2B3VU%3D","line":300,"updated":"2014-02-18 15:09:31.000000000","message":"Is there a specific exception we can catch? If we really want to use the diaper pattern a comment may be helpful.","commit_id":"46c72279a629a6d0f51869460ea977c0afcc824a"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"80ab90eda19681e2dd685c1ad6f80581cc173958","unresolved":false,"context_lines":[{"line_number":297,"context_line":"    if notifier:"},{"line_number":298,"context_line":"        try:"},{"line_number":299,"context_line":"            notifier.info(context, event_type, payload)"},{"line_number":300,"context_line":"        except Exception:"},{"line_number":301,"context_line":"            LOG.exception(_(\u0027Failed to send %(action)s %(event_type)s\u0027"},{"line_number":302,"context_line":"                            \u0027 notification\u0027), msg_data)"},{"line_number":303,"context_line":""}],"source_content_type":"text/x-python","patch_set":23,"id":"AAAAUX%2F%2B3BI%3D","line":300,"in_reply_to":"AAAAUX%2F%2B3VU%3D","updated":"2014-02-18 15:17:54.000000000","message":"++ for diaper pattern here (also i\u0027ve never heard that term but i deem it to be awesomely accurate); one of the few places i think we should use it","commit_id":"46c72279a629a6d0f51869460ea977c0afcc824a"}],"keystone/tests/test_notifications.py":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"da42f1bbd45f0f55c495d51becf54bdee616a087","unresolved":false,"context_lines":[{"line_number":388,"context_line":""},{"line_number":389,"context_line":"        fixture \u003d self.useFixture(moxstubout.MoxStubout())"},{"line_number":390,"context_line":"        self.stubs \u003d fixture.stubs"},{"line_number":391,"context_line":"        self.stubs.Set(cadf_notifications, \u0027_send_notification\u0027, fake_notify)"},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":394,"context_line":"    def authenticate(self, context, auth\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F90nk%3D","line":391,"updated":"2014-02-03 16:26:24.000000000","message":"might be better to stubout notifier_api.notify() rather than _send_notification as it currently stubouts the CADF event generation and only tests that the wrapper is called.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":388,"context_line":""},{"line_number":389,"context_line":"        fixture \u003d self.useFixture(moxstubout.MoxStubout())"},{"line_number":390,"context_line":"        self.stubs \u003d fixture.stubs"},{"line_number":391,"context_line":"        self.stubs.Set(cadf_notifications, \u0027_send_notification\u0027, fake_notify)"},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"    @cadf_notifications.emit_event(\u0027authenticate\u0027)"},{"line_number":394,"context_line":"    def authenticate(self, context, auth\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xV0%3D","line":391,"in_reply_to":"AAAAUH%2F90nk%3D","updated":"2014-02-04 05:43:51.000000000","message":"This is modeled after the keystone notifications class which stubs at the _send_notification method so I am going to keep it consistent with that class","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"4a81c19f2dbc4c88044bbe8aa2ede2c5055b0c4e","unresolved":false,"context_lines":[{"line_number":395,"context_line":"        return auth"},{"line_number":396,"context_line":""},{"line_number":397,"context_line":"    def test_v3_authenticate(self):"},{"line_number":398,"context_line":"        self.exp_action \u003d \u0027authenticate\u0027"},{"line_number":399,"context_line":"        self.exp_http_user_agent \u003d uuid.uuid4().hex"},{"line_number":400,"context_line":"        self.exp_remote_addr \u003d \u0027127.0.0.1\u0027"},{"line_number":401,"context_line":"        self.exp_user_name \u003d uuid.uuid4().hex"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xTM%3D","line":398,"updated":"2014-02-04 05:58:11.000000000","message":"Will you be asserting these values after the call is made? Otherwise you can just call them in the function args.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ae2d677bedef809574a31ffaafcbc1a37b0fdba7","unresolved":false,"context_lines":[{"line_number":395,"context_line":"        return auth"},{"line_number":396,"context_line":""},{"line_number":397,"context_line":"    def test_v3_authenticate(self):"},{"line_number":398,"context_line":"        self.exp_action \u003d \u0027authenticate\u0027"},{"line_number":399,"context_line":"        self.exp_http_user_agent \u003d uuid.uuid4().hex"},{"line_number":400,"context_line":"        self.exp_remote_addr \u003d \u0027127.0.0.1\u0027"},{"line_number":401,"context_line":"        self.exp_user_name \u003d uuid.uuid4().hex"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9jA4%3D","line":398,"in_reply_to":"AAAAUH%2F9xTM%3D","updated":"2014-02-06 05:38:12.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"4a81c19f2dbc4c88044bbe8aa2ede2c5055b0c4e","unresolved":false,"context_lines":[{"line_number":397,"context_line":"    def test_v3_authenticate(self):"},{"line_number":398,"context_line":"        self.exp_action \u003d \u0027authenticate\u0027"},{"line_number":399,"context_line":"        self.exp_http_user_agent \u003d uuid.uuid4().hex"},{"line_number":400,"context_line":"        self.exp_remote_addr \u003d \u0027127.0.0.1\u0027"},{"line_number":401,"context_line":"        self.exp_user_name \u003d uuid.uuid4().hex"},{"line_number":402,"context_line":"        context \u003d {"},{"line_number":403,"context_line":"            \u0027environment\u0027: {"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9xTE%3D","line":400,"updated":"2014-02-04 05:58:11.000000000","message":"You can probably get rid of making these class variables, take a look at _assertLastNotify.","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ae2d677bedef809574a31ffaafcbc1a37b0fdba7","unresolved":false,"context_lines":[{"line_number":397,"context_line":"    def test_v3_authenticate(self):"},{"line_number":398,"context_line":"        self.exp_action \u003d \u0027authenticate\u0027"},{"line_number":399,"context_line":"        self.exp_http_user_agent \u003d uuid.uuid4().hex"},{"line_number":400,"context_line":"        self.exp_remote_addr \u003d \u0027127.0.0.1\u0027"},{"line_number":401,"context_line":"        self.exp_user_name \u003d uuid.uuid4().hex"},{"line_number":402,"context_line":"        context \u003d {"},{"line_number":403,"context_line":"            \u0027environment\u0027: {"}],"source_content_type":"text/x-python","patch_set":6,"id":"AAAAUH%2F9jBE%3D","line":400,"in_reply_to":"AAAAUH%2F9xTE%3D","updated":"2014-02-06 05:38:12.000000000","message":"Done","commit_id":"83325a603b2d30329bf45350ea63514d52d6bd13"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"51b1606ef83e24bd3e1626a0953bffacef7e22fc","unresolved":false,"context_lines":[{"line_number":416,"context_line":"                        \u0027identity\u0027: {"},{"line_number":417,"context_line":"                            \u0027password\u0027: {\u0027user\u0027: {\u0027name\u0027: exp_user_name}}}}}}}"},{"line_number":418,"context_line":"        self.authenticate(context, None)"},{"line_number":419,"context_line":"        self.assertTrue(self.send_notification_called)"},{"line_number":420,"context_line":"        self._assertLastNotify(exp_action, exp_http_user_agent,"},{"line_number":421,"context_line":"                               exp_remote_addr, exp_user_name)"},{"line_number":422,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAUH%2F9i%2B8%3D","line":419,"updated":"2014-02-06 05:53:16.000000000","message":"you can eliminate this line since it\u0027s done in the _assertLastNotify function","commit_id":"57b358d70a8c910f83a4d935b2804f1cac8a0e91"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"96bc6421c2781e5bf9c15d54f168b2cb07031bcc","unresolved":false,"context_lines":[{"line_number":416,"context_line":"                        \u0027identity\u0027: {"},{"line_number":417,"context_line":"                            \u0027password\u0027: {\u0027user\u0027: {\u0027name\u0027: exp_user_name}}}}}}}"},{"line_number":418,"context_line":"        self.authenticate(context, None)"},{"line_number":419,"context_line":"        self.assertTrue(self.send_notification_called)"},{"line_number":420,"context_line":"        self._assertLastNotify(exp_action, exp_http_user_agent,"},{"line_number":421,"context_line":"                               exp_remote_addr, exp_user_name)"},{"line_number":422,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAUH%2F9dXY%3D","line":419,"in_reply_to":"AAAAUH%2F9i%2B8%3D","updated":"2014-02-06 19:18:59.000000000","message":"Good catch!  Will fix when I get to NY tonight","commit_id":"57b358d70a8c910f83a4d935b2804f1cac8a0e91"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"51b1606ef83e24bd3e1626a0953bffacef7e22fc","unresolved":false,"context_lines":[{"line_number":434,"context_line":"                        \u0027passwordCredentials\u0027: {"},{"line_number":435,"context_line":"                            \u0027username\u0027: exp_user_name}}}}}"},{"line_number":436,"context_line":"        self.authenticate(context, None)"},{"line_number":437,"context_line":"        self.assertTrue(self.send_notification_called)"},{"line_number":438,"context_line":"        self._assertLastNotify(exp_action, exp_http_user_agent,"},{"line_number":439,"context_line":"                               exp_remote_addr, exp_user_name)"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAAUH%2F9i%2Bs%3D","line":437,"updated":"2014-02-06 05:53:16.000000000","message":"same here too.","commit_id":"57b358d70a8c910f83a4d935b2804f1cac8a0e91"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":443,"context_line":"                \u0027send_notification_called\u0027: True}"},{"line_number":444,"context_line":"            self._notifications.append(note)"},{"line_number":445,"context_line":""},{"line_number":446,"context_line":"        fixture \u003d self.useFixture(moxstubout.MoxStubout())"},{"line_number":447,"context_line":"        self.stubs \u003d fixture.stubs"},{"line_number":448,"context_line":"        self.stubs.Set(cadf_notifications, \u0027_send_audit_notification\u0027,"},{"line_number":449,"context_line":"                       fake_notify)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIdI%3D","line":446,"updated":"2014-02-16 16:37:50.000000000","message":"suggest use mockpatch instead. OpenStack seems to be moving to mock rather than mox.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":443,"context_line":"                \u0027send_notification_called\u0027: True}"},{"line_number":444,"context_line":"            self._notifications.append(note)"},{"line_number":445,"context_line":""},{"line_number":446,"context_line":"        fixture \u003d self.useFixture(moxstubout.MoxStubout())"},{"line_number":447,"context_line":"        self.stubs \u003d fixture.stubs"},{"line_number":448,"context_line":"        self.stubs.Set(cadf_notifications, \u0027_send_audit_notification\u0027,"},{"line_number":449,"context_line":"                       fake_notify)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FITQ%3D","line":446,"in_reply_to":"AAAAUX%2F%2FIdI%3D","updated":"2014-02-16 18:53:05.000000000","message":"I\u0027ve noticed this trend, but I\u0027ve never used mockpatch, are you okay with making this a TODO and fixing it later/","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":449,"context_line":"                       fake_notify)"},{"line_number":450,"context_line":""},{"line_number":451,"context_line":"    def _assertLastNotify(self, action, remote_addr, http_user_agent, user_id):"},{"line_number":452,"context_line":"        self.assertTrue(len(self._notifications) \u003e 0)"},{"line_number":453,"context_line":"        note \u003d self._notifications[-1]"},{"line_number":454,"context_line":"        self.assertEqual(note[\u0027action\u0027], action)"},{"line_number":455,"context_line":"        self.assertEqual(note[\u0027remote_addr\u0027], remote_addr)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIdE%3D","line":452,"updated":"2014-02-16 16:37:50.000000000","message":"use self.assertTrue(self._notifications) since don\u0027t care about the actual length.","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":449,"context_line":"                       fake_notify)"},{"line_number":450,"context_line":""},{"line_number":451,"context_line":"    def _assertLastNotify(self, action, remote_addr, http_user_agent, user_id):"},{"line_number":452,"context_line":"        self.assertTrue(len(self._notifications) \u003e 0)"},{"line_number":453,"context_line":"        note \u003d self._notifications[-1]"},{"line_number":454,"context_line":"        self.assertEqual(note[\u0027action\u0027], action)"},{"line_number":455,"context_line":"        self.assertEqual(note[\u0027remote_addr\u0027], remote_addr)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FITs%3D","line":452,"in_reply_to":"AAAAUX%2F%2FIdE%3D","updated":"2014-02-16 18:53:05.000000000","message":"Done","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"}],"keystone/token/controllers.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        cert_file.close()"},{"line_number":58,"context_line":"        return data"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    #BT wrap with decorator that then does notification"},{"line_number":61,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":62,"context_line":"    @controller.v2_deprecated"},{"line_number":63,"context_line":"    def authenticate(self, context, auth\u003dNone):"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BNag%3D","line":60,"updated":"2014-01-29 02:07:35.000000000","message":"you don\u0027t need to sign inline comments, unless you\u0027re writing a novel\n\n  # NOTE(btopol): Now, this is the story all about how...","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"ea9565c3e32856eac3ad0d54ac64d3f07f2cd8a4","unresolved":false,"context_lines":[{"line_number":57,"context_line":"        cert_file.close()"},{"line_number":58,"context_line":"        return data"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    #BT wrap with decorator that then does notification"},{"line_number":61,"context_line":"    @cadf_notifications.emit_cadf_event(\u0027authenticate\u0027)"},{"line_number":62,"context_line":"    @controller.v2_deprecated"},{"line_number":63,"context_line":"    def authenticate(self, context, auth\u003dNone):"}],"source_content_type":"text/x-python","patch_set":2,"id":"AAAAUH%2F%2BMiM%3D","line":60,"in_reply_to":"AAAAUH%2F%2BNag%3D","updated":"2014-01-29 06:53:34.000000000","message":"will remove. I put that in when you and I were talking in San Antonio as a placeholder for when I got back and was able to start coding","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"eb8254f735ca77d52df2d1ba32059cd88ea5dc4d","unresolved":false,"context_lines":[{"line_number":473,"context_line":"                \u0027endpoints\u0027: ["},{"line_number":474,"context_line":"                    {"},{"line_number":475,"context_line":"                        \u0027id\u0027: $endpoint_id,"},{"line_number":476,"context_line":"                        \u0027name\u0027: $SERVICE[name],"},{"line_number":477,"context_line":"                        \u0027type\u0027: $SERVICE,"},{"line_number":478,"context_line":"                        \u0027tenantId\u0027: $tenant_id,"},{"line_number":479,"context_line":"                        \u0027region\u0027: $REGION,"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAUX%2F%2FMss%3D","side":"PARENT","line":476,"updated":"2014-02-14 23:21:12.000000000","message":"why\u0027d you remove this?","commit_id":"e8f8c1774983bf9d190d6452bfb98b88bf80a36b"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"eb8254f735ca77d52df2d1ba32059cd88ea5dc4d","unresolved":false,"context_lines":[{"line_number":103,"context_line":"        # part of the token data. The token provider doesn\u0027t care about the"},{"line_number":104,"context_line":"        # format."},{"line_number":105,"context_line":"        user_ref \u003d self.v3_to_v2_user(user_ref)"},{"line_number":106,"context_line":"        # The user_ref is encoded into the auth_token_data which is returned as"},{"line_number":107,"context_line":"        # part of the token data. The token provider doesn\u0027t care about the"},{"line_number":108,"context_line":"        # format."},{"line_number":109,"context_line":"        user_ref \u003d self.v3_to_v2_user(user_ref)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAAUX%2F%2FMs0%3D","line":106,"updated":"2014-02-14 23:21:12.000000000","message":"this seems duped","commit_id":"4af2e61083c9891b3a49666c8abced0b8fd7851b"},{"author":{"_account_id":6486,"name":"Brant Knudson","email":"blk@acm.org","username":"blk-u"},"change_message_id":"1845b97eadae84d9e5ae18db177c6958be199457","unresolved":false,"context_lines":[{"line_number":471,"context_line":"        The v2.0 API wants an endpoint list to look like::"},{"line_number":472,"context_line":""},{"line_number":473,"context_line":"            {"},{"line_number":474,"context_line":"                \u0027endpoints\u0027: ["},{"line_number":475,"context_line":"                        \u0027tenantId\u0027: $tenant_id,"},{"line_number":476,"context_line":"                        \u0027region\u0027: $REGION,"},{"line_number":477,"context_line":"                    }"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIdA%3D","line":474,"updated":"2014-02-16 16:37:50.000000000","message":"what\u0027s with this change?","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f3b8f003e419ade7ab26fad313f38a5dde81556e","unresolved":false,"context_lines":[{"line_number":471,"context_line":"        The v2.0 API wants an endpoint list to look like::"},{"line_number":472,"context_line":""},{"line_number":473,"context_line":"            {"},{"line_number":474,"context_line":"                \u0027endpoints\u0027: ["},{"line_number":475,"context_line":"                        \u0027tenantId\u0027: $tenant_id,"},{"line_number":476,"context_line":"                        \u0027region\u0027: $REGION,"},{"line_number":477,"context_line":"                    }"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAAUX%2F%2FIUY%3D","line":474,"in_reply_to":"AAAAUX%2F%2FIdA%3D","updated":"2014-02-16 18:53:05.000000000","message":"reverting...","commit_id":"c07554b8a03e5ce85a37b58316d35f78b3e9b226"}],"requirements.txt":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"9a4d9d31ef58825cef032611537f62cc3cb760bb","unresolved":false,"context_lines":[{"line_number":27,"context_line":"pecan\u003e\u003d0.2.0"},{"line_number":28,"context_line":"pycrypto\u003e\u003d2.6"},{"line_number":29,"context_line":"WSME\u003e\u003d0.5b6"},{"line_number":30,"context_line":""}],"source_content_type":"text/plain","patch_set":2,"id":"AAAAUH%2F%2BNZs%3D","line":30,"updated":"2014-01-29 02:07:35.000000000","message":"remove extra whitespace -- i don\u0027t think flake8 will catch this","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"bff863b4262a93fad8931c190660e975b4f445e4","unresolved":false,"context_lines":[{"line_number":27,"context_line":"pecan\u003e\u003d0.2.0"},{"line_number":28,"context_line":"pycrypto\u003e\u003d2.6"},{"line_number":29,"context_line":"WSME\u003e\u003d0.5b6"},{"line_number":30,"context_line":""}],"source_content_type":"text/plain","patch_set":2,"id":"AAAAUH%2F%2BIag%3D","line":30,"in_reply_to":"AAAAUH%2F%2BNZs%3D","updated":"2014-01-29 21:12:50.000000000","message":"do you mean lines 24 and 26?   Those were already in there. You want me to take them out?","commit_id":"c783bb5bc645d68fa803766c87d05a5306d4a956"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"4ea3f690c803d2e4e83cfa637e4a826434d62926","unresolved":false,"context_lines":[{"line_number":27,"context_line":"pecan\u003e\u003d0.2.0"},{"line_number":28,"context_line":"pycrypto\u003e\u003d2.6"},{"line_number":29,"context_line":"WSME\u003e\u003d0.5b6"},{"line_number":30,"context_line":""}],"source_content_type":"text/plain","patch_set":5,"id":"AAAAUH%2F94R0%3D","line":30,"updated":"2014-02-02 19:42:33.000000000","message":"Extra line here?","commit_id":"9091e4ca813da3179f8d0eba0df2bebfd88bd818"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"4970f30661b9faa586ed325a80ed9863f70c192e","unresolved":false,"context_lines":[{"line_number":27,"context_line":"pecan\u003e\u003d0.2.0"},{"line_number":28,"context_line":"pycrypto\u003e\u003d2.6"},{"line_number":29,"context_line":"WSME\u003e\u003d0.5b6"},{"line_number":30,"context_line":""}],"source_content_type":"text/plain","patch_set":5,"id":"AAAAUH%2F94HA%3D","line":30,"in_reply_to":"AAAAUH%2F94R0%3D","updated":"2014-02-02 19:48:11.000000000","message":"Will remove it","commit_id":"9091e4ca813da3179f8d0eba0df2bebfd88bd818"}],"test-requirements.txt":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"4ea3f690c803d2e4e83cfa637e4a826434d62926","unresolved":false,"context_lines":[{"line_number":35,"context_line":"# replaces httplib2 in keystoneclient \u003e\u003d0.2.1"},{"line_number":36,"context_line":"requests\u003e\u003d1.1"},{"line_number":37,"context_line":"keyring\u003e\u003d1.6.1,\u003c2.0,\u003e\u003d2.1"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"# For documentation"},{"line_number":40,"context_line":"oslo.sphinx"}],"source_content_type":"text/plain","patch_set":5,"id":"AAAAUH%2F94Rw%3D","side":"PARENT","line":38,"updated":"2014-02-02 19:42:33.000000000","message":"Why remove this line?","commit_id":"51602dcc25cd2070eccdf4d9d5957b42d825d1bf"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"4970f30661b9faa586ed325a80ed9863f70c192e","unresolved":false,"context_lines":[{"line_number":35,"context_line":"# replaces httplib2 in keystoneclient \u003e\u003d0.2.1"},{"line_number":36,"context_line":"requests\u003e\u003d1.1"},{"line_number":37,"context_line":"keyring\u003e\u003d1.6.1,\u003c2.0,\u003e\u003d2.1"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"# For documentation"},{"line_number":40,"context_line":"oslo.sphinx"}],"source_content_type":"text/plain","patch_set":5,"id":"AAAAUH%2F94HE%3D","side":"PARENT","line":38,"in_reply_to":"AAAAUH%2F94Rw%3D","updated":"2014-02-02 19:48:11.000000000","message":"Didnt mean too.  Accidentally changed the file and though I changed it back to its original condition.  Will fix in the next patch set","commit_id":"51602dcc25cd2070eccdf4d9d5957b42d825d1bf"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"da42f1bbd45f0f55c495d51becf54bdee616a087","unresolved":false,"context_lines":[{"line_number":35,"context_line":"# replaces httplib2 in keystoneclient \u003e\u003d0.2.1"},{"line_number":36,"context_line":"requests\u003e\u003d1.1"},{"line_number":37,"context_line":"keyring\u003e\u003d1.6.1,\u003c2.0,\u003e\u003d2.1"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"# For documentation"},{"line_number":40,"context_line":"oslo.sphinx"}],"source_content_type":"text/plain","patch_set":6,"id":"AAAAUH%2F90tk%3D","side":"PARENT","line":38,"updated":"2014-02-03 16:26:24.000000000","message":"don\u0027t think this change is needed","commit_id":"51602dcc25cd2070eccdf4d9d5957b42d825d1bf"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"49ba307953907ec88b3b27a678fe80fb1b6ed043","unresolved":false,"context_lines":[{"line_number":35,"context_line":"# replaces httplib2 in keystoneclient \u003e\u003d0.2.1"},{"line_number":36,"context_line":"requests\u003e\u003d1.1"},{"line_number":37,"context_line":"keyring\u003e\u003d1.6.1,\u003c2.0,\u003e\u003d2.1"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"# For documentation"},{"line_number":40,"context_line":"oslo.sphinx"}],"source_content_type":"text/plain","patch_set":6,"id":"AAAAUH%2F9xf8%3D","side":"PARENT","line":38,"in_reply_to":"AAAAUH%2F90tk%3D","updated":"2014-02-04 04:46:06.000000000","message":"++ revert the white space change","commit_id":"51602dcc25cd2070eccdf4d9d5957b42d825d1bf"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"1199d828fcef6f5de3ec8ac08a3df4819dc8da06","unresolved":false,"context_lines":[{"line_number":35,"context_line":"# replaces httplib2 in keystoneclient \u003e\u003d0.2.1"},{"line_number":36,"context_line":"requests\u003e\u003d1.1"},{"line_number":37,"context_line":"keyring\u003e\u003d1.6.1,\u003c2.0,\u003e\u003d2.1"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"# For documentation"},{"line_number":40,"context_line":"oslo.sphinx"}],"source_content_type":"text/plain","patch_set":6,"id":"AAAAUH%2F9xVw%3D","side":"PARENT","line":38,"in_reply_to":"AAAAUH%2F9xf8%3D","updated":"2014-02-04 05:43:51.000000000","message":"Done","commit_id":"51602dcc25cd2070eccdf4d9d5957b42d825d1bf"}]}
