)]}'
{"oslo_context/context.py":[{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"81531cad087b42f1e37c2c50d23f8694157871d0","unresolved":false,"context_lines":[{"line_number":63,"context_line":"        \"\"\""},{"line_number":64,"context_line":"        self.auth_token \u003d auth_token"},{"line_number":65,"context_line":"        self.user \u003d user"},{"line_number":66,"context_line":"        self.user_name \u003d user_name"},{"line_number":67,"context_line":"        # NOTE (rbradfor):  tenant will become project"},{"line_number":68,"context_line":"        # See spec discussion on https://review.openstack.org/#/c/290907/"},{"line_number":69,"context_line":"        self.tenant \u003d tenant"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_0a8eaf78","line":66,"range":{"start_line":66,"start_character":25,"end_line":66,"end_character":34},"updated":"2016-05-16 00:14:33.000000000","message":"whilst i agree user_name is more consistent i\u0027ve been stung by this before where people expect it to be username and get confused otherwise.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"4e066cc53dbed41c8c42d9b28e949dc8b85a2aea","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                  \u0027domain_name\u0027: self.domain_name,"},{"line_number":138,"context_line":"                  \u0027user_domain_name\u0027: self.user_domain_name,"},{"line_number":139,"context_line":"                  \u0027project_domain_name\u0027: self.project_domain_name}"},{"line_number":140,"context_line":"        values.update(self.to_dict())"},{"line_number":141,"context_line":"        return values"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_aa2acc8d","line":140,"range":{"start_line":140,"start_character":27,"end_line":140,"end_character":34},"updated":"2016-05-11 00:11:42.000000000","message":"I know it\u0027s already there, but i dislike this. There\u0027s no reason to pass everything in to_dict to logging. I would think the point here is to only add things that logging actually wants to this dict.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":16051,"name":"Ronald Bradford","email":"ronald.bradford@gmail.com","username":"ronaldbradford"},"change_message_id":"e4b274e9cedb001f2e9feeef9f035827fbc73cb0","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                  \u0027domain_name\u0027: self.domain_name,"},{"line_number":138,"context_line":"                  \u0027user_domain_name\u0027: self.user_domain_name,"},{"line_number":139,"context_line":"                  \u0027project_domain_name\u0027: self.project_domain_name}"},{"line_number":140,"context_line":"        values.update(self.to_dict())"},{"line_number":141,"context_line":"        return values"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_adb56232","line":140,"range":{"start_line":140,"start_character":27,"end_line":140,"end_character":34},"in_reply_to":"dab17558_586bffb6","updated":"2016-05-12 15:41:30.000000000","message":"@Jamie,  could you help me understand what you mean by credentials dict?\n\nolso.logging can either access a context object, or be passed a context object.  \nThere is a way to pass a dictionary as context\u003d, but I\u0027d like to propose we deprecate this approach so we can remove it\u0027s usage.\n\nhopefully from the policy side, and from the context args revisions we can solve this concurrently.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":16051,"name":"Ronald Bradford","email":"ronald.bradford@gmail.com","username":"ronaldbradford"},"change_message_id":"4bb4a9e0f89bded433e2ba42cbe731a6d5b44f36","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                  \u0027domain_name\u0027: self.domain_name,"},{"line_number":138,"context_line":"                  \u0027user_domain_name\u0027: self.user_domain_name,"},{"line_number":139,"context_line":"                  \u0027project_domain_name\u0027: self.project_domain_name}"},{"line_number":140,"context_line":"        values.update(self.to_dict())"},{"line_number":141,"context_line":"        return values"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_c948d5b5","line":140,"range":{"start_line":140,"start_character":27,"end_line":140,"end_character":34},"in_reply_to":"dab17558_aa2acc8d","updated":"2016-05-11 16:32:54.000000000","message":"I agree with you, but the code to use get_logging_values is still not deployed https://review.openstack.org/#/c/274188/.\n\nIt will take a log longer to extract out for logging what is really needed in context base, and per project.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"f4757b39803789725e59f1f7171cea998076052b","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                  \u0027domain_name\u0027: self.domain_name,"},{"line_number":138,"context_line":"                  \u0027user_domain_name\u0027: self.user_domain_name,"},{"line_number":139,"context_line":"                  \u0027project_domain_name\u0027: self.project_domain_name}"},{"line_number":140,"context_line":"        values.update(self.to_dict())"},{"line_number":141,"context_line":"        return values"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_7b99651f","line":140,"range":{"start_line":140,"start_character":27,"end_line":140,"end_character":34},"in_reply_to":"dab17558_adb56232","updated":"2016-05-12 22:25:36.000000000","message":"So with policy (for whatever reason) you pass in a dictionary and most services create this dictionary themselves, it typically involves the roles, project and user ids.\n\nMy goal was to replace this individual building with the to_policy_values function above, but for most services this is slightly wrong. For example they pass user\u003duser_id, where i want to standardize on user_id\u003duser_id, so services will have to override the to_policy_values function for a while to add that user until it can be completely deprecated. I\u0027m playing with some ways of helping that deprecation process [1].\n\nIn the same way any service that relies on additional options in logging can just override the get_logging_values() function and add what they need - but it is different because it\u0027s oslo.log which was calling the to_dict.\n\n\n[1] https://review.openstack.org/#/c/314901/","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"9679e0bea8e03debd4cca02058feea79fdf1fa4a","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                  \u0027domain_name\u0027: self.domain_name,"},{"line_number":138,"context_line":"                  \u0027user_domain_name\u0027: self.user_domain_name,"},{"line_number":139,"context_line":"                  \u0027project_domain_name\u0027: self.project_domain_name}"},{"line_number":140,"context_line":"        values.update(self.to_dict())"},{"line_number":141,"context_line":"        return values"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @classmethod"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_586bffb6","line":140,"range":{"start_line":140,"start_character":27,"end_line":140,"end_character":34},"in_reply_to":"dab17558_c948d5b5","updated":"2016-05-12 00:12:25.000000000","message":"So my feeling here was always that if a project needed something specific in addition to the defaults they would override get_logging_values() and add whatever they need.\n\nThe migration is an issue as i see that oslo.logging expects to be passed an oslo.context directly, as opposed to oslo.policy which expects a credentials dict.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"}],"oslo_context/tests/test_context.py":[{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"6c9ba323da2e4a76ba5bc6cbcc1e44d4eb4d32cb","unresolved":false,"context_lines":[{"line_number":150,"context_line":"        user_name \u003d uuid.uuid4().hex"},{"line_number":151,"context_line":"        user_id \u003d generate_id(user_name)"},{"line_number":152,"context_line":"        project_name \u003d uuid.uuid4().hex"},{"line_number":153,"context_line":"        project_id \u003d generate_id(project_name)"},{"line_number":154,"context_line":"        user_domain_name \u003d uuid.uuid4().hex"},{"line_number":155,"context_line":"        user_domain_id \u003d generate_id(user_domain_name)"},{"line_number":156,"context_line":"        project_domain_name \u003d uuid.uuid4().hex"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab17558_6dc91e59","line":153,"range":{"start_line":153,"start_character":21,"end_line":153,"end_character":32},"updated":"2016-05-11 00:13:13.000000000","message":"not sure i see any advantage to using a hash here rather than just another uuid. There is no such link from name to id in keystone.","commit_id":"343ecb2179c0dff7e044b37cc4690f2a5dc9dec9"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"29679464b52a7c8ccb73a5c865459743541f5834","unresolved":false,"context_lines":[{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def generate_id(name):"},{"line_number":27,"context_line":"    return hashlib.md5(name.encode(\u0027utf-8\u0027)).hexdigest()"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"class Object(object):"}],"source_content_type":"text/x-python","patch_set":2,"id":"7aa08908_f84877b5","line":27,"updated":"2016-06-17 00:43:34.000000000","message":"there is no relationship between name and id. just use uuid.uuid4().hex for test ids.","commit_id":"f0de0c6291600706fe13db201f203f9da8f5d45c"}]}
