)]}'
{"keystone/tests/unit/test_v3_federation.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":2570,"context_line":"        r2 \u003d self._issue_unscoped_token()"},{"line_number":2571,"context_line":"        t2_resp \u003d r2.json_body[\u0027token\u0027]"},{"line_number":2572,"context_line":""},{"line_number":2573,"context_line":"        self.assertEqual(t1_resp[\u0027user\u0027][\u0027id\u0027], t2_resp[\u0027user\u0027][\u0027id\u0027])"},{"line_number":2574,"context_line":""},{"line_number":2575,"context_line":"    def test_user_role_assignment(self):"},{"line_number":2576,"context_line":"        \"\"\"Test..."}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_6d75a0f8","line":2573,"updated":"2016-02-29 17:39:17.000000000","message":"++","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":2570,"context_line":"        r2 \u003d self._issue_unscoped_token()"},{"line_number":2571,"context_line":"        t2_resp \u003d r2.json_body[\u0027token\u0027]"},{"line_number":2572,"context_line":""},{"line_number":2573,"context_line":"        self.assertEqual(t1_resp[\u0027user\u0027][\u0027id\u0027], t2_resp[\u0027user\u0027][\u0027id\u0027])"},{"line_number":2574,"context_line":""},{"line_number":2575,"context_line":"    def test_user_role_assignment(self):"},{"line_number":2576,"context_line":"        \"\"\"Test..."}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_f90cceed","line":2573,"in_reply_to":"9aed3d3a_6d75a0f8","updated":"2016-02-29 18:43:50.000000000","message":"this should be in https://review.openstack.org/#/c/27916","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":2579,"context_line":"        2. get back a user ID"},{"line_number":2580,"context_line":"        3. have an admin user directly assign that user a role in a project"},{"line_number":2581,"context_line":"        4. have the federated user get a token for the project"},{"line_number":2582,"context_line":"        5. ensure user can access resource based on role assignment"},{"line_number":2583,"context_line":""},{"line_number":2584,"context_line":"        \"\"\""},{"line_number":2585,"context_line":"        r \u003d self._issue_unscoped_token()"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_cdb82c78","line":2582,"updated":"2016-02-29 17:39:17.000000000","message":"The old 5 should still be here! But we can pursue that in Newton (it\u0027s a matter of cleaning up tech debt).","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"}],"keystone/token/providers/common.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":597,"context_line":"                auth_context, project_id, domain_id)"},{"line_number":598,"context_line":""},{"line_number":599,"context_line":"        access_token \u003d None"},{"line_number":600,"context_line":"        if \u0027oauth1\u0027 in method_names:"},{"line_number":601,"context_line":"            access_token_id \u003d auth_context[\u0027access_token_id\u0027]"},{"line_number":602,"context_line":"            access_token \u003d self.oauth_api.get_access_token(access_token_id)"},{"line_number":603,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_08f16201","side":"PARENT","line":600,"updated":"2016-02-29 17:39:17.000000000","message":"nit: not that it seems to matter, but why did the order of this change?","commit_id":"abd302acf3f94fa9609d1b3a7cb7bf639237b3ae"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":597,"context_line":"                auth_context, project_id, domain_id)"},{"line_number":598,"context_line":""},{"line_number":599,"context_line":"        access_token \u003d None"},{"line_number":600,"context_line":"        if \u0027oauth1\u0027 in method_names:"},{"line_number":601,"context_line":"            access_token_id \u003d auth_context[\u0027access_token_id\u0027]"},{"line_number":602,"context_line":"            access_token \u003d self.oauth_api.get_access_token(access_token_id)"},{"line_number":603,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_5d8165c2","side":"PARENT","line":600,"in_reply_to":"9aed3d3a_08f16201","updated":"2016-02-29 18:43:50.000000000","message":"i am passing access_token to populate_roles() in line 623","commit_id":"abd302acf3f94fa9609d1b3a7cb7bf639237b3ae"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":334,"context_line":"        roles \u003d self.assignment_api.get_roles_for_groups(group_ids,"},{"line_number":335,"context_line":"                                                         project_id,"},{"line_number":336,"context_line":"                                                         domain_id)"},{"line_number":337,"context_line":"        # check_roles(roles, user_id, project_id, domain_id)"},{"line_number":338,"context_line":"        token_data[\u0027roles\u0027] \u003d roles"},{"line_number":339,"context_line":""},{"line_number":340,"context_line":"    def _populate_user(self, token_data, user_id, trust):"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_883292f0","line":337,"updated":"2016-02-29 17:39:17.000000000","message":"We need to keep this, right?","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":616,"context_line":"                auth_context, project_id, domain_id)"},{"line_number":617,"context_line":""},{"line_number":618,"context_line":"            if project_id or domain_id:"},{"line_number":619,"context_line":""},{"line_number":620,"context_line":"                try:"},{"line_number":621,"context_line":"                    self.v3_token_data_helper._populate_roles("},{"line_number":622,"context_line":"                        token_ref, user_id, domain_id, project_id, trust,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_48b1aa46","line":619,"updated":"2016-02-29 17:39:17.000000000","message":"nit: random whitespace","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":616,"context_line":"                auth_context, project_id, domain_id)"},{"line_number":617,"context_line":""},{"line_number":618,"context_line":"            if project_id or domain_id:"},{"line_number":619,"context_line":""},{"line_number":620,"context_line":"                try:"},{"line_number":621,"context_line":"                    self.v3_token_data_helper._populate_roles("},{"line_number":622,"context_line":"                        token_ref, user_id, domain_id, project_id, trust,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_3da8e1da","line":619,"in_reply_to":"9aed3d3a_48b1aa46","updated":"2016-02-29 18:43:50.000000000","message":"Done","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":622,"context_line":"                        token_ref, user_id, domain_id, project_id, trust,"},{"line_number":623,"context_line":"                        access_token)"},{"line_number":624,"context_line":""},{"line_number":625,"context_line":"                except exception.Unauthorized, e:"},{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_a864b6b8","line":625,"updated":"2016-02-29 17:39:17.000000000","message":"nit: old style exceptions","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":622,"context_line":"                        token_ref, user_id, domain_id, project_id, trust,"},{"line_number":623,"context_line":"                        access_token)"},{"line_number":624,"context_line":""},{"line_number":625,"context_line":"                except exception.Unauthorized, e:"},{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_9db12d4a","line":625,"in_reply_to":"9aed3d3a_a864b6b8","updated":"2016-02-29 18:43:50.000000000","message":"Done","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":623,"context_line":"                        access_token)"},{"line_number":624,"context_line":""},{"line_number":625,"context_line":"                except exception.Unauthorized, e:"},{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"},{"line_number":629,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_48fb6ac1","line":626,"updated":"2016-02-29 17:39:17.000000000","message":"So, swallowing exception is obviously bad. This must be the bit you wanted me to review this morning :P\n\nI\u0027m trying to figure out how the populate_roles functions would throw Unauthorized in any way that we\u0027d care about...","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":623,"context_line":"                        access_token)"},{"line_number":624,"context_line":""},{"line_number":625,"context_line":"                except exception.Unauthorized, e:"},{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"},{"line_number":629,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_ddf0d593","line":626,"in_reply_to":"9aed3d3a_48fb6ac1","updated":"2016-02-29 18:43:50.000000000","message":"I am unsure if we can remove raising exception.Unauthorized from methods like _populate_roles() or _populate_roles_from_groups() and handle that situation in a layer up (if roles is None or not roles: raise Unatuhorized()) I am just fearing that somewhere in the code somebody may be depending that those functions would raise exception themselves.","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"                    self.v3_token_data_helper.extend_roles_for_groups("},{"line_number":631,"context_line":"                        token_ref, auth_context[\u0027group_ids\u0027],"},{"line_number":632,"context_line":"                        project_id, domain_id, user_id)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_a8a156fa","line":629,"updated":"2016-02-29 17:39:17.000000000","message":"nit: random whitespace","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":626,"context_line":"                    pass"},{"line_number":627,"context_line":""},{"line_number":628,"context_line":"                try:"},{"line_number":629,"context_line":""},{"line_number":630,"context_line":"                    self.v3_token_data_helper.extend_roles_for_groups("},{"line_number":631,"context_line":"                        token_ref, auth_context[\u0027group_ids\u0027],"},{"line_number":632,"context_line":"                        project_id, domain_id, user_id)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_ddb73538","line":629,"in_reply_to":"9aed3d3a_a8a156fa","updated":"2016-02-29 18:43:50.000000000","message":"Done","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":631,"context_line":"                        token_ref, auth_context[\u0027group_ids\u0027],"},{"line_number":632,"context_line":"                        project_id, domain_id, user_id)"},{"line_number":633,"context_line":"                except exception.Unauthorized:"},{"line_number":634,"context_line":"                    pass"},{"line_number":635,"context_line":""},{"line_number":636,"context_line":"                if not token_ref or not token_ref.get(\u0027roles\u0027):"},{"line_number":637,"context_line":"                    raise exception.Unauthorized(\"Authorization failed\")"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_28f8a6c2","line":634,"updated":"2016-02-29 17:39:17.000000000","message":"Same","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":631,"context_line":"                        token_ref, auth_context[\u0027group_ids\u0027],"},{"line_number":632,"context_line":"                        project_id, domain_id, user_id)"},{"line_number":633,"context_line":"                except exception.Unauthorized:"},{"line_number":634,"context_line":"                    pass"},{"line_number":635,"context_line":""},{"line_number":636,"context_line":"                if not token_ref or not token_ref.get(\u0027roles\u0027):"},{"line_number":637,"context_line":"                    raise exception.Unauthorized(\"Authorization failed\")"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_5df16500","line":634,"in_reply_to":"9aed3d3a_28f8a6c2","updated":"2016-02-29 18:43:50.000000000","message":"Done","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"22ba44ffd044799006a30cc3e1e801052314cdf9","unresolved":false,"context_lines":[{"line_number":635,"context_line":""},{"line_number":636,"context_line":"                if not token_ref or not token_ref.get(\u0027roles\u0027):"},{"line_number":637,"context_line":"                    raise exception.Unauthorized(\"Authorization failed\")"},{"line_number":638,"context_line":""},{"line_number":639,"context_line":""},{"line_number":640,"context_line":"        token_data \u003d self.v3_token_data_helper.get_token_data("},{"line_number":641,"context_line":"            user_id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_286706ea","line":638,"updated":"2016-02-29 17:39:17.000000000","message":"nit: random whitespace","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"},{"author":{"_account_id":8978,"name":"Marek Denis","email":"marek.denis+openstack@gmail.com","username":"marek-denis"},"change_message_id":"19a77c32160cd2731c29f80c2918ef81a477c360","unresolved":false,"context_lines":[{"line_number":635,"context_line":""},{"line_number":636,"context_line":"                if not token_ref or not token_ref.get(\u0027roles\u0027):"},{"line_number":637,"context_line":"                    raise exception.Unauthorized(\"Authorization failed\")"},{"line_number":638,"context_line":""},{"line_number":639,"context_line":""},{"line_number":640,"context_line":"        token_data \u003d self.v3_token_data_helper.get_token_data("},{"line_number":641,"context_line":"            user_id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9aed3d3a_1dd23d5c","line":638,"in_reply_to":"9aed3d3a_286706ea","updated":"2016-02-29 18:43:50.000000000","message":"Done","commit_id":"1ccbe1402807d27bdafaf10ef5270b868a5830d8"}]}
