)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0d7a7756dea4912f41be8e5775cfe17df039e39b","unresolved":false,"context_lines":[{"line_number":10,"context_line":"Adjust both template and sql driver to omit services without endpoints when"},{"line_number":11,"context_line":"formatting the urls."},{"line_number":12,"context_line":"In turn, omit endpoints with urls that may not be formatted correctly."},{"line_number":13,"context_line":"Added tests to verify for templated driver and sql driver."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Closes Bug: #1436704"},{"line_number":16,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":9,"id":"3afb71cf_f861e4d3","line":13,"updated":"2015-06-10 18:39:21.000000000","message":"This part feels like a separate change. I\u0027m not sure how much Keystone should be validating URLs outside of jsonschema, but I\u0027m not sure it belongs with this commit.","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"2210e2d8673b7444de03b0229021788c7c0f6008","unresolved":false,"context_lines":[{"line_number":10,"context_line":"Adjust both template and sql driver to omit services without endpoints when"},{"line_number":11,"context_line":"formatting the urls."},{"line_number":12,"context_line":"In turn, omit endpoints with urls that may not be formatted correctly."},{"line_number":13,"context_line":"Added tests to verify for templated driver and sql driver."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"Closes Bug: #1436704"},{"line_number":16,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":9,"id":"3afb71cf_2f7b94bf","line":13,"in_reply_to":"3afb71cf_f861e4d3","updated":"2015-06-11 11:40:39.000000000","message":"I think you\u0027re reading \u0027may\u0027 differently to how I meant it.  I meant \u0027may\u0027 not in the sense that the url might be odd - but in the sense that it cannot be formatted due to the absence of a value.  You\u0027re right in a way that there are two changes but they are so closely related - removing endpoints without valid urls and removing services without endpoints - that it makes sense to put them together.\n\nI\u0027ve changed the commit message to attempt clarification.","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Dave Chen \u003cdave.jungler@gmail.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-07-30 07:53:14 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Remove services with no endpoints from catalog"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"When formatting the urls for endpoints omit those that cannot be formatted"},{"line_number":10,"context_line":"correctly."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"3a50d1a3_ae0af925","line":7,"updated":"2015-07-30 09:28:33.000000000","message":"the title is misleading now. It should be something like \"exclude from output\" or \"omit from response\". Nothing gets removed from the database, right?","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"}],"keystone/catalog/backends/sql.py":[{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""},{"line_number":426,"context_line":"        if (CONF.endpoint_filter.return_all_endpoints_if_no_filter and"},{"line_number":427,"context_line":"                not (tenant_id and associations)):"},{"line_number":428,"context_line":"            # if there are no endpoints assigned to the project check"},{"line_number":429,"context_line":"            # whether all endpoints should be returned"},{"line_number":430,"context_line":"            return unfiltered_catalog"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_eb77a0d2","line":427,"updated":"2015-04-28 03:13:28.000000000","message":"if not tenant_id then associations will be not defined? although short-circuit will ignore that but I think it\u0027s not necessary to check associations here.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""},{"line_number":426,"context_line":"        if (CONF.endpoint_filter.return_all_endpoints_if_no_filter and"},{"line_number":427,"context_line":"                not (tenant_id and associations)):"},{"line_number":428,"context_line":"            # if there are no endpoints assigned to the project check"},{"line_number":429,"context_line":"            # whether all endpoints should be returned"},{"line_number":430,"context_line":"            return unfiltered_catalog"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_90828551","line":427,"in_reply_to":"7ad32947_301dff73","updated":"2015-04-28 13:52:01.000000000","message":"I miss that, thanks David.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"45a1fd0b5424e6c1ef4315ad4bd83ea1407e4f8c","unresolved":false,"context_lines":[{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""},{"line_number":426,"context_line":"        if (CONF.endpoint_filter.return_all_endpoints_if_no_filter and"},{"line_number":427,"context_line":"                not (tenant_id and associations)):"},{"line_number":428,"context_line":"            # if there are no endpoints assigned to the project check"},{"line_number":429,"context_line":"            # whether all endpoints should be returned"},{"line_number":430,"context_line":"            return unfiltered_catalog"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_301dff73","line":427,"in_reply_to":"7ad32947_eb77a0d2","updated":"2015-04-28 08:40:17.000000000","message":"In the case of the project having no associated endpoints then \u0027associations\u0027 here can be None even when tenant_id is set.  If that is the case and CONF.endpoint_filter.return_all_endpoints_if_no_filter is True then we need to return the unfiltered catalog.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"5ba08fe1042671502507fd458fefe168ac593893","unresolved":false,"context_lines":[{"line_number":419,"context_line":"                unfiltered_catalog.append(catalog_service)"},{"line_number":420,"context_line":""},{"line_number":421,"context_line":"        # if this is a project scoped token - get the project associations"},{"line_number":422,"context_line":"        if tenant_id:"},{"line_number":423,"context_line":"            associations \u003d self.endpoint_filter_api.list_endpoints_for_project("},{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_5ef1c2cc","line":422,"updated":"2015-04-29 16:41:38.000000000","message":"this seem differ from the parent patch","commit_id":"4b38336c71583554e5bfc6da86be721f430d29d5"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"a2a950c44ec4040288bcecc99fad640f124e5c53","unresolved":false,"context_lines":[{"line_number":419,"context_line":"                unfiltered_catalog.append(catalog_service)"},{"line_number":420,"context_line":""},{"line_number":421,"context_line":"        # if this is a project scoped token - get the project associations"},{"line_number":422,"context_line":"        if tenant_id:"},{"line_number":423,"context_line":"            associations \u003d self.endpoint_filter_api.list_endpoints_for_project("},{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_ef59fa8f","line":422,"in_reply_to":"3acd31a7_5ef1c2cc","updated":"2015-04-29 18:15:28.000000000","message":"Do you mean you think I should pull it up into the parent?","commit_id":"4b38336c71583554e5bfc6da86be721f430d29d5"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"9b1e0b23a3a8a2e522cf32716a3b71487c9a04a1","unresolved":false,"context_lines":[{"line_number":419,"context_line":"                unfiltered_catalog.append(catalog_service)"},{"line_number":420,"context_line":""},{"line_number":421,"context_line":"        # if this is a project scoped token - get the project associations"},{"line_number":422,"context_line":"        if tenant_id:"},{"line_number":423,"context_line":"            associations \u003d self.endpoint_filter_api.list_endpoints_for_project("},{"line_number":424,"context_line":"                tenant_id)"},{"line_number":425,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_80da5377","line":422,"in_reply_to":"3acd31a7_ef59fa8f","updated":"2015-04-29 19:24:01.000000000","message":"no, I mean the parent changes should be here","commit_id":"4b38336c71583554e5bfc6da86be721f430d29d5"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0d7a7756dea4912f41be8e5775cfe17df039e39b","unresolved":false,"context_lines":[{"line_number":382,"context_line":"        def make_v3_service(svc):"},{"line_number":383,"context_line":"            eps \u003d list(make_v3_endpoints(svc.endpoints))"},{"line_number":384,"context_line":"            if len(eps) \u003d\u003d 0:"},{"line_number":385,"context_line":"                return"},{"line_number":386,"context_line":"            service \u003d {\u0027endpoints\u0027: eps, \u0027id\u0027: svc.id, \u0027type\u0027: svc.type}"},{"line_number":387,"context_line":"            service[\u0027name\u0027] \u003d svc.extra.get(\u0027name\u0027, \u0027\u0027)"},{"line_number":388,"context_line":"            return service"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_d8fd08b2","line":385,"updated":"2015-06-10 18:39:21.000000000","message":"nit: \n\nShould be able to do the same with: \n\n    if not eps:\n        return","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"2210e2d8673b7444de03b0229021788c7c0f6008","unresolved":false,"context_lines":[{"line_number":382,"context_line":"        def make_v3_service(svc):"},{"line_number":383,"context_line":"            eps \u003d list(make_v3_endpoints(svc.endpoints))"},{"line_number":384,"context_line":"            if len(eps) \u003d\u003d 0:"},{"line_number":385,"context_line":"                return"},{"line_number":386,"context_line":"            service \u003d {\u0027endpoints\u0027: eps, \u0027id\u0027: svc.id, \u0027type\u0027: svc.type}"},{"line_number":387,"context_line":"            service[\u0027name\u0027] \u003d svc.extra.get(\u0027name\u0027, \u0027\u0027)"},{"line_number":388,"context_line":"            return service"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_0ff1f86a","line":385,"in_reply_to":"3afb71cf_d8fd08b2","updated":"2015-06-11 11:40:39.000000000","message":"I\u0027ve taken care of this but actually by reversing the condition and returning explicitly only once and then with a dict rather than initialising \u0027service\u0027 to a dict and returning that.","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":409,"context_line":"                                                   \u0027type\u0027: service[\u0027type\u0027]}"},{"line_number":410,"context_line":"                        endpoint_lookup_dict[endpoint[\u0027id\u0027]] \u003d new_endpoint"},{"line_number":411,"context_line":"            return endpoint_lookup_dict"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"        unfiltered_catalog \u003d [make_v3_service(svc) for svc in all_services]"},{"line_number":414,"context_line":""},{"line_number":415,"context_line":"        if tenant_id:"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_115a2c2b","side":"PARENT","line":412,"updated":"2015-07-30 09:28:33.000000000","message":"the newline should be kept as it was","commit_id":"564044b939995b89069703ca4585d13647fa1390"}],"keystone/catalog/backends/templated.py":[{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":145,"context_line":"                            service_data[k] \u003d formatted_value"},{"line_number":146,"context_line":"                except exception.MalformedEndpoint:"},{"line_number":147,"context_line":"                    continue  # this failure is already logged in format_url()"},{"line_number":148,"context_line":"                if (service_data.get(\u0027adminURL\u0027)"},{"line_number":149,"context_line":"                        or service_data.get(\u0027publicURL\u0027)"},{"line_number":150,"context_line":"                        or service_data.get(\u0027internalURL\u0027)):"},{"line_number":151,"context_line":"                    catalog[region][service] \u003d service_data"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_94e2aa2e","line":148,"updated":"2015-07-30 09:28:33.000000000","message":"I wonder if this check should go before \"catalog[region] \u003d {}\". It will save us formatting if there are no urls, but can it happen that there will be urls before formatting, but won\u0027t after?\n\nOK, lets keep it here just to be sure.","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"}],"keystone/tests/unit/test_backend_sql.py":[{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":1013,"context_line":"            \u0027region_id\u0027: None,"},{"line_number":1014,"context_line":"            \u0027service_id\u0027: port_sub_service[\u0027id\u0027],"},{"line_number":1015,"context_line":"            \u0027interface\u0027: \u0027admin\u0027,"},{"line_number":1016,"context_line":"            \u0027url\u0027: \u0027http://localhost:$(admin_port)s/v2.0\u0027,"},{"line_number":1017,"context_line":"        }"},{"line_number":1018,"context_line":"        self.catalog_api.create_endpoint(internal_endpoint[\u0027id\u0027],"},{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_15b1c78f","line":1016,"updated":"2015-04-28 13:52:01.000000000","message":"s/admin_port/internal_port","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"bcb80c6589fd35960334853a4129123a4551b97b","unresolved":false,"context_lines":[{"line_number":1013,"context_line":"            \u0027region_id\u0027: None,"},{"line_number":1014,"context_line":"            \u0027service_id\u0027: port_sub_service[\u0027id\u0027],"},{"line_number":1015,"context_line":"            \u0027interface\u0027: \u0027admin\u0027,"},{"line_number":1016,"context_line":"            \u0027url\u0027: \u0027http://localhost:$(admin_port)s/v2.0\u0027,"},{"line_number":1017,"context_line":"        }"},{"line_number":1018,"context_line":"        self.catalog_api.create_endpoint(internal_endpoint[\u0027id\u0027],"},{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ad0253b_9b809348","line":1016,"in_reply_to":"7ad32947_15b1c78f","updated":"2015-04-28 16:26:50.000000000","message":"Done.  Sort of.  The substitution used the config \u0027admin_port\u0027 property.  There is no corresponding \u0027internal_port\u0027 property so I\u0027ve dropped this endpoint.  It\u0027s not important for the test and less is more.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_ee256ec2","line":1022,"updated":"2015-04-28 03:13:28.000000000","message":"skip the catalog entirely instead of the endpoint.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_d51d8f67","line":1022,"in_reply_to":"7ad32947_9a9bd1c9","updated":"2015-04-28 13:52:01.000000000","message":"Hmmm, sorry, my words is not clear, I meant the key issue you want to fix in this patch is the service should be skipped if there no endpoints bundled with that service. The comment leads me to think the patch here want to address the issue which we have been addressed.\n\nskip the *service* not skip the catalog, sorry for my incorrect comments.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"bcb80c6589fd35960334853a4129123a4551b97b","unresolved":false,"context_lines":[{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ad0253b_5bc1db7f","line":1022,"in_reply_to":"7ad32947_d51d8f67","updated":"2015-04-28 16:26:50.000000000","message":"Done.  I\u0027ve tried to clarify.  There is a underlying cause and a consequence to get across here so my new comment is a little bit chatty.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"45a1fd0b5424e6c1ef4315ad4bd83ea1407e4f8c","unresolved":false,"context_lines":[{"line_number":1019,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_9a9bd1c9","line":1022,"in_reply_to":"7ad32947_ee256ec2","updated":"2015-04-28 08:40:17.000000000","message":"I don\u0027t understand this comment.  My belief is that if an endpoint cannot have a properly formatted url then that endpoint should not appear in the catalog.  It should not have an effect on other endpoints, services or the catalog in total.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"},{"line_number":1026,"context_line":"        self.assertEqual(port_sub_service[\u0027type\u0027], catalog[0][\u0027type\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_4e36a204","line":1023,"updated":"2015-04-28 03:13:28.000000000","message":"here, it\u0027s suppose to replace %user_id with user_id but the endpoint has no such placeholder, besides, I think there is only `tenant_id` and `user_id` is allowed in the template, core reviewers may help to confirm that.\n\nsuggest to update the definition of the service with valid substitution.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"45a1fd0b5424e6c1ef4315ad4bd83ea1407e4f8c","unresolved":false,"context_lines":[{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"},{"line_number":1026,"context_line":"        self.assertEqual(port_sub_service[\u0027type\u0027], catalog[0][\u0027type\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_7aeeb523","line":1023,"in_reply_to":"7ad32947_4e36a204","updated":"2015-04-28 08:40:17.000000000","message":"This test is aimed at ensuring that endpoints without valid formatted urls are not featured in the catalog.  I could add an endpoint with a substitution for user_id but this call is just to get the catalog for a given user but no tenant scoped.  If it\u0027s not a valid use case then maybe I can adjust the test.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":1020,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1021,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1022,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1023,"context_line":"        catalog \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1024,"context_line":"        self.assertEqual(1, len(catalog))"},{"line_number":1025,"context_line":"        self.assertEqual(port_sub_service[\u0027name\u0027], catalog[0][\u0027name\u0027])"},{"line_number":1026,"context_line":"        self.assertEqual(port_sub_service[\u0027type\u0027], catalog[0][\u0027type\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_954a7782","line":1023,"in_reply_to":"7ad32947_7aeeb523","updated":"2015-04-28 13:52:01.000000000","message":"David, I just come across to see some comment in this bug: https://bugs.launchpad.net/keystone/+bug/1383817, but I also saw the default_catalog.templates still use it, so I think we can let it opens to others.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":1115,"context_line":"            \u0027region_id\u0027: region[\u0027id\u0027],"},{"line_number":1116,"context_line":"            \u0027service_id\u0027: port_sub_service[\u0027id\u0027],"},{"line_number":1117,"context_line":"            \u0027interface\u0027: \u0027admin\u0027,"},{"line_number":1118,"context_line":"            \u0027url\u0027: \u0027http://localhost:$(admin_port)s/v2.0\u0027,"},{"line_number":1119,"context_line":"        }"},{"line_number":1120,"context_line":"        self.catalog_api.create_endpoint(internal_endpoint[\u0027id\u0027],"},{"line_number":1121,"context_line":"                                         internal_endpoint.copy())"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_9074c59c","line":1118,"updated":"2015-04-28 13:52:01.000000000","message":"nits, s/admin/inernal","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"bcb80c6589fd35960334853a4129123a4551b97b","unresolved":false,"context_lines":[{"line_number":1115,"context_line":"            \u0027region_id\u0027: region[\u0027id\u0027],"},{"line_number":1116,"context_line":"            \u0027service_id\u0027: port_sub_service[\u0027id\u0027],"},{"line_number":1117,"context_line":"            \u0027interface\u0027: \u0027admin\u0027,"},{"line_number":1118,"context_line":"            \u0027url\u0027: \u0027http://localhost:$(admin_port)s/v2.0\u0027,"},{"line_number":1119,"context_line":"        }"},{"line_number":1120,"context_line":"        self.catalog_api.create_endpoint(internal_endpoint[\u0027id\u0027],"},{"line_number":1121,"context_line":"                                         internal_endpoint.copy())"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ad0253b_5bf67bd8","line":1118,"in_reply_to":"7ad32947_9074c59c","updated":"2015-04-28 16:26:50.000000000","message":"As above.  Sort of done.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":1121,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1122,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1123,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1124,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1125,"context_line":"        catalog \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"        catalog_service \u003d catalog[region[\u0027id\u0027]][port_sub_service[\u0027type\u0027]]"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_0e40aa55","line":1124,"updated":"2015-04-28 03:13:28.000000000","message":"skip the catalog entirely instead of the endpoint.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"45a1fd0b5424e6c1ef4315ad4bd83ea1407e4f8c","unresolved":false,"context_lines":[{"line_number":1121,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1122,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":1123,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1124,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1125,"context_line":"        catalog \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"        catalog_service \u003d catalog[region[\u0027id\u0027]][port_sub_service[\u0027type\u0027]]"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_bae44d3b","line":1124,"in_reply_to":"7ad32947_0e40aa55","updated":"2015-04-28 08:40:17.000000000","message":"As above.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":1123,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1124,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1125,"context_line":"        catalog \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"        catalog_service \u003d catalog[region[\u0027id\u0027]][port_sub_service[\u0027type\u0027]]"},{"line_number":1128,"context_line":""},{"line_number":1129,"context_line":"        self.assertEqual(1, len(catalog))"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_2e3b66ed","line":1126,"updated":"2015-04-28 03:13:28.000000000","message":"same here.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"45a1fd0b5424e6c1ef4315ad4bd83ea1407e4f8c","unresolved":false,"context_lines":[{"line_number":1123,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":1124,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":1125,"context_line":"        catalog \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"        catalog_service \u003d catalog[region[\u0027id\u0027]][port_sub_service[\u0027type\u0027]]"},{"line_number":1128,"context_line":""},{"line_number":1129,"context_line":"        self.assertEqual(1, len(catalog))"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_5acad9a2","line":1126,"in_reply_to":"7ad32947_2e3b66ed","updated":"2015-04-28 08:40:17.000000000","message":"As above.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0d7a7756dea4912f41be8e5775cfe17df039e39b","unresolved":false,"context_lines":[{"line_number":1006,"context_line":""},{"line_number":1007,"context_line":"    def test_get_v3_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1008,"context_line":"        \"\"\"Check that catalog for domain scoped token omits services that"},{"line_number":1009,"context_line":"         require project scope for url formatting"},{"line_number":1010,"context_line":"         \"\"\""},{"line_number":1011,"context_line":""},{"line_number":1012,"context_line":"        tenant_sub_service \u003d {"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_18f7208c","line":1009,"updated":"2015-06-10 18:39:21.000000000","message":"nit: suggest following the multiline pep8 convention; \n\nhttps://www.python.org/dev/peps/pep-0257/#multi-line-docstrings\n\nwhere the first line consists of a summary and then more detail can be added after the new line. \n\n    def test_my_awesome_feature(self):\n    \"\"\"Raise an exception if bar is None.\n\n    If variable bar is ...\n\n    \"\"\"","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"2210e2d8673b7444de03b0229021788c7c0f6008","unresolved":false,"context_lines":[{"line_number":1006,"context_line":""},{"line_number":1007,"context_line":"    def test_get_v3_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1008,"context_line":"        \"\"\"Check that catalog for domain scoped token omits services that"},{"line_number":1009,"context_line":"         require project scope for url formatting"},{"line_number":1010,"context_line":"         \"\"\""},{"line_number":1011,"context_line":""},{"line_number":1012,"context_line":"        tenant_sub_service \u003d {"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_8f70480c","line":1009,"in_reply_to":"3afb71cf_18f7208c","updated":"2015-06-11 11:40:39.000000000","message":"Done","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0d7a7756dea4912f41be8e5775cfe17df039e39b","unresolved":false,"context_lines":[{"line_number":1096,"context_line":""},{"line_number":1097,"context_line":"    def test_get_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1098,"context_line":"        \"\"\"Check that catalog for domain scoped token omits services that"},{"line_number":1099,"context_line":"         require project scope for url formatting"},{"line_number":1100,"context_line":"         \"\"\""},{"line_number":1101,"context_line":"        region \u003d {"},{"line_number":1102,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_b8636c41","line":1099,"updated":"2015-06-10 18:39:21.000000000","message":"same comment here","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"2210e2d8673b7444de03b0229021788c7c0f6008","unresolved":false,"context_lines":[{"line_number":1096,"context_line":""},{"line_number":1097,"context_line":"    def test_get_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1098,"context_line":"        \"\"\"Check that catalog for domain scoped token omits services that"},{"line_number":1099,"context_line":"         require project scope for url formatting"},{"line_number":1100,"context_line":"         \"\"\""},{"line_number":1101,"context_line":"        region \u003d {"},{"line_number":1102,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_4f76d006","line":1099,"in_reply_to":"3afb71cf_b8636c41","updated":"2015-06-11 11:40:39.000000000","message":"Done","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0d7a7756dea4912f41be8e5775cfe17df039e39b","unresolved":false,"context_lines":[{"line_number":1109,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"},{"line_number":1110,"context_line":"            \u0027type\u0027: uuid.uuid4().hex,"},{"line_number":1111,"context_line":"            \u0027name\u0027: uuid.uuid4().hex,"},{"line_number":1112,"context_line":"            \u0027description\u0027: uuid.uuid4().hex,"},{"line_number":1113,"context_line":"        }"},{"line_number":1114,"context_line":"        self.catalog_api.create_service(tenant_sub_service[\u0027id\u0027],"},{"line_number":1115,"context_line":"                                        tenant_sub_service.copy())"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_18016038","line":1112,"updated":"2015-06-10 18:39:21.000000000","message":"Could some of the reference generation be shared between these two tests? Some of the test_v3 test modules have reference generation methods, I wonder if they could be used here instead of making more of them?","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"2210e2d8673b7444de03b0229021788c7c0f6008","unresolved":false,"context_lines":[{"line_number":1109,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"},{"line_number":1110,"context_line":"            \u0027type\u0027: uuid.uuid4().hex,"},{"line_number":1111,"context_line":"            \u0027name\u0027: uuid.uuid4().hex,"},{"line_number":1112,"context_line":"            \u0027description\u0027: uuid.uuid4().hex,"},{"line_number":1113,"context_line":"        }"},{"line_number":1114,"context_line":"        self.catalog_api.create_service(tenant_sub_service[\u0027id\u0027],"},{"line_number":1115,"context_line":"                                        tenant_sub_service.copy())"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_2f71540c","line":1112,"in_reply_to":"3afb71cf_18016038","updated":"2015-06-11 11:40:39.000000000","message":"Done","commit_id":"35c13bb0146fb88ed08f91757eac3e30d1741100"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":864,"context_line":"    _enabled_default_to_true_when_creating_endpoint \u003d True"},{"line_number":865,"context_line":""},{"line_number":866,"context_line":"    def test_catalog_ignored_malformed_urls(self):"},{"line_number":867,"context_line":"        service \u003d self.create_service_dict()"},{"line_number":868,"context_line":"        self.catalog_api.create_service(service[\u0027id\u0027], service.copy())"},{"line_number":869,"context_line":""},{"line_number":870,"context_line":"        malformed_url \u003d \"http://192.168.1.104:8774/v2/$(tenant)s\""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_74535ee3","line":867,"updated":"2015-07-30 09:28:33.000000000","message":"although I support the switch to create_service_dict, it should be done in a separate patch","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":992,"context_line":"            \u0027name\u0027: uuid.uuid4().hex,"},{"line_number":993,"context_line":"            \u0027description\u0027: uuid.uuid4().hex,"},{"line_number":994,"context_line":"        }"},{"line_number":995,"context_line":"        return tenant_sub_service"},{"line_number":996,"context_line":""},{"line_number":997,"context_line":"    def create_endpoint_dict(self, service_id\u003dNone,"},{"line_number":998,"context_line":"                             interface\u003dNone, url_pattern\u003dNone, region_id\u003dNone):"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_d46d929a","line":995,"updated":"2015-07-30 09:28:33.000000000","message":"the variable here has nothing to do with tenants, especially if you\u0027re going to use it above. Please rename it from tenant_sub_service to something else.","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":1010,"context_line":"        tenant_sub_service \u003d self.create_service_dict()"},{"line_number":1011,"context_line":"        self.catalog_api.create_service(tenant_sub_service[\u0027id\u0027],"},{"line_number":1012,"context_line":"                                        tenant_sub_service.copy())"},{"line_number":1013,"context_line":"        public_endpoint \u003d self.create_endpoint_dict("},{"line_number":1014,"context_line":"            service_id\u003dtenant_sub_service[\u0027id\u0027],"},{"line_number":1015,"context_line":"            interface\u003d\u0027public\u0027,"},{"line_number":1016,"context_line":"            url_pattern\u003d\u0027http://localhost:8774/v1.1/$(tenant_id)s\u0027,"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_b40a4626","line":1013,"updated":"2015-07-30 09:28:33.000000000","message":"please, add some comments. Something like \"# create service 1 with 3 endpoints\". It will be much easier to read the code.","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":1075,"context_line":"        self.assertEqual(service[\u0027id\u0027], catalog[0][\u0027id\u0027])"},{"line_number":1076,"context_line":"        endpoint_id_list \u003d [endpoint[\u0027id\u0027]"},{"line_number":1077,"context_line":"                            for endpoint in catalog[0][\u0027endpoints\u0027]]"},{"line_number":1078,"context_line":"        self.assertTrue(public_endpoint[\u0027id\u0027] in endpoint_id_list)"},{"line_number":1079,"context_line":"        self.assertTrue(admin_endpoint[\u0027id\u0027] in endpoint_id_list)"},{"line_number":1080,"context_line":""},{"line_number":1081,"context_line":"    def test_get_catalog_ignores_endpoints_with_invalid_urls(self):"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_f7f0d0ff","line":1078,"updated":"2015-07-30 09:28:33.000000000","message":"assertIn should be used here and below","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"                          self.catalog_api.delete_region,"},{"line_number":1006,"context_line":"                          region[\u0027id\u0027])"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"    def create_service_dict(self):"},{"line_number":1009,"context_line":"        service \u003d {"},{"line_number":1010,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"},{"line_number":1011,"context_line":"            \u0027type\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_6f4f5c34","line":1008,"updated":"2015-08-26 13:50:17.000000000","message":"this should probably be a private method.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1005,"context_line":"                          self.catalog_api.delete_region,"},{"line_number":1006,"context_line":"                          region[\u0027id\u0027])"},{"line_number":1007,"context_line":""},{"line_number":1008,"context_line":"    def create_service_dict(self):"},{"line_number":1009,"context_line":"        service \u003d {"},{"line_number":1010,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"},{"line_number":1011,"context_line":"            \u0027type\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_0d21e59d","line":1008,"in_reply_to":"fa1b9901_6f4f5c34","updated":"2015-09-07 10:34:45.000000000","message":"Done","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1014,"context_line":"        }"},{"line_number":1015,"context_line":"        return service"},{"line_number":1016,"context_line":""},{"line_number":1017,"context_line":"    def create_endpoint_dict(self, service_id\u003dNone,"},{"line_number":1018,"context_line":"                             interface\u003dNone, url_pattern\u003dNone, region_id\u003dNone):"},{"line_number":1019,"context_line":"        public_endpoint \u003d {"},{"line_number":1020,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_8f4c3043","line":1017,"updated":"2015-08-26 13:50:17.000000000","message":"same comment here.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1014,"context_line":"        }"},{"line_number":1015,"context_line":"        return service"},{"line_number":1016,"context_line":""},{"line_number":1017,"context_line":"    def create_endpoint_dict(self, service_id\u003dNone,"},{"line_number":1018,"context_line":"                             interface\u003dNone, url_pattern\u003dNone, region_id\u003dNone):"},{"line_number":1019,"context_line":"        public_endpoint \u003d {"},{"line_number":1020,"context_line":"            \u0027id\u0027: uuid.uuid4().hex,"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_cd376de1","line":1017,"in_reply_to":"fa1b9901_8f4c3043","updated":"2015-09-07 10:34:45.000000000","message":"Done","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1025,"context_line":"        }"},{"line_number":1026,"context_line":"        return public_endpoint"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"    def create_test_endpoints(self, region_id\u003dNone):"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        tenant_sub_service \u003d self.create_service_dict()"},{"line_number":1031,"context_line":"        self.catalog_api.create_service(tenant_sub_service[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_cf3d488f","line":1028,"updated":"2015-08-26 13:50:17.000000000","message":"same comment here.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1025,"context_line":"        }"},{"line_number":1026,"context_line":"        return public_endpoint"},{"line_number":1027,"context_line":""},{"line_number":1028,"context_line":"    def create_test_endpoints(self, region_id\u003dNone):"},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        tenant_sub_service \u003d self.create_service_dict()"},{"line_number":1031,"context_line":"        self.catalog_api.create_service(tenant_sub_service[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_6d32e1f3","line":1028,"in_reply_to":"fa1b9901_cf3d488f","updated":"2015-09-07 10:34:45.000000000","message":"Done","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1053,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1054,"context_line":""},{"line_number":1055,"context_line":"        port_sub_service \u003d self.create_service_dict()"},{"line_number":1056,"context_line":"        self.catalog_api.create_service(port_sub_service[\u0027id\u0027],"},{"line_number":1057,"context_line":"                                        port_sub_service.copy())"},{"line_number":1058,"context_line":"        valid_public_endpoint \u003d self.create_endpoint_dict("},{"line_number":1059,"context_line":"            service_id\u003dport_sub_service[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_6f43dcaf","line":1056,"updated":"2015-08-26 13:50:17.000000000","message":"we already have some logic that creates services, and its inherited through the CatalogTests class. It would be awesome to see some of these utility methods consolidated rather than each class in the hierarchy having their own version.\n\nSounds like a good place for a mix-in or just some utility function in CatalogTests.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1053,"context_line":"                                         internal_endpoint.copy())"},{"line_number":1054,"context_line":""},{"line_number":1055,"context_line":"        port_sub_service \u003d self.create_service_dict()"},{"line_number":1056,"context_line":"        self.catalog_api.create_service(port_sub_service[\u0027id\u0027],"},{"line_number":1057,"context_line":"                                        port_sub_service.copy())"},{"line_number":1058,"context_line":"        valid_public_endpoint \u003d self.create_endpoint_dict("},{"line_number":1059,"context_line":"            service_id\u003dport_sub_service[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_cdcbed70","line":1056,"in_reply_to":"fa1b9901_6f43dcaf","updated":"2015-09-07 10:34:45.000000000","message":"CatalogTests is not in the SqlCatalogV3 hierarchy as it carries with it a lot of extra tests that don\u0027t work when inherited there.  I agree that there is a need for some improvement/refactoring to the utility methods but perhaps it should be a separate patch set.  I think the utility methods should be separated from actual test methods in the class structure - something that\u0027s not evident in CatalogTests - which itself I think is version (V2/V3) specific.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1072,"context_line":""},{"line_number":1073,"context_line":"        return port_sub_service, valid_admin_endpoint, valid_public_endpoint"},{"line_number":1074,"context_line":""},{"line_number":1075,"context_line":"    def test_get_v3_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1076,"context_line":"        \"\"\"Check catalog scope"},{"line_number":1077,"context_line":""},{"line_number":1078,"context_line":"         Ensure for domain scoped token that catalog omits services that"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_2fa724be","line":1075,"updated":"2015-08-26 13:50:17.000000000","message":"should this test live in SqlCatalogV3 ?","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1072,"context_line":""},{"line_number":1073,"context_line":"        return port_sub_service, valid_admin_endpoint, valid_public_endpoint"},{"line_number":1074,"context_line":""},{"line_number":1075,"context_line":"    def test_get_v3_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":1076,"context_line":"        \"\"\"Check catalog scope"},{"line_number":1077,"context_line":""},{"line_number":1078,"context_line":"         Ensure for domain scoped token that catalog omits services that"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_6d49815f","line":1075,"in_reply_to":"fa1b9901_2fa724be","updated":"2015-09-07 10:34:45.000000000","message":"Done","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"2652bf796b405c90328ebda66e0d58aff6020f53","unresolved":false,"context_lines":[{"line_number":1076,"context_line":"        \"\"\"Check catalog scope"},{"line_number":1077,"context_line":""},{"line_number":1078,"context_line":"         Ensure for domain scoped token that catalog omits services that"},{"line_number":1079,"context_line":"         require project scope for url formatting"},{"line_number":1080,"context_line":"         \"\"\""},{"line_number":1081,"context_line":""},{"line_number":1082,"context_line":"        service, admin_endpoint, public_endpoint \u003d self.create_test_endpoints()"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa1b9901_8fe8b0e3","line":1079,"updated":"2015-08-26 13:50:17.000000000","message":"nit: add period to end of this doc string.","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"ab72aef412408f13c81f1e8832085a415a3c2261","unresolved":false,"context_lines":[{"line_number":1076,"context_line":"        \"\"\"Check catalog scope"},{"line_number":1077,"context_line":""},{"line_number":1078,"context_line":"         Ensure for domain scoped token that catalog omits services that"},{"line_number":1079,"context_line":"         require project scope for url formatting"},{"line_number":1080,"context_line":"         \"\"\""},{"line_number":1081,"context_line":""},{"line_number":1082,"context_line":"        service, admin_endpoint, public_endpoint \u003d self.create_test_endpoints()"}],"source_content_type":"text/x-python","patch_set":16,"id":"da20952f_8d441547","line":1079,"in_reply_to":"fa1b9901_8fe8b0e3","updated":"2015-09-07 10:34:45.000000000","message":"Done","commit_id":"f5482bc5390c4afda01d66a3d5f797a21c704473"}],"keystone/tests/unit/test_backend_templated.py":[{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"26a25cccf15ae883d9c9bc2c0857fbb2cd3868a0","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def test_get_catalog(self):"},{"line_number":62,"context_line":"        catalog_ref \u003d self.catalog_api.get_catalog(\u0027foo\u0027, \u0027bar\u0027)"},{"line_number":63,"context_line":"        self.assertDictEqual(self.DEFAULT_FIXTURE, catalog_ref)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    def test_catalog_ignored_malformed_urls(self):"},{"line_number":66,"context_line":"        # both endpoints are in the catalog"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_4eeea223","line":63,"updated":"2015-04-28 03:13:28.000000000","message":"nice catch :-)","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"bcb80c6589fd35960334853a4129123a4551b97b","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"    def test_get_catalog(self):"},{"line_number":62,"context_line":"        catalog_ref \u003d self.catalog_api.get_catalog(\u0027foo\u0027, \u0027bar\u0027)"},{"line_number":63,"context_line":"        self.assertDictEqual(self.DEFAULT_FIXTURE, catalog_ref)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    def test_catalog_ignored_malformed_urls(self):"},{"line_number":66,"context_line":"        # both endpoints are in the catalog"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ad0253b_3b1a9f18","line":63,"in_reply_to":"7ad32947_4eeea223","updated":"2015-04-28 16:26:50.000000000","message":"Thank you.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"4298c44e3da277ddea463a7cab47bdf701114ee3","unresolved":false,"context_lines":[{"line_number":145,"context_line":"    def test_get_v2_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":146,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":147,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":148,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":149,"context_line":"        catalog_ref \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"        expected \u003d self.DEFAULT_FIXTURE.copy()"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ad32947_90d3a538","line":148,"updated":"2015-04-28 13:52:01.000000000","message":"It would be nice if we can aslo change the comment here, since what this patch intends to fix is the ignore the service instead of just ignore some endpoints.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":9276,"name":"David Charles Kennedy","email":"david.c.kennedy@hpe.com","username":"darfed"},"change_message_id":"bcb80c6589fd35960334853a4129123a4551b97b","unresolved":false,"context_lines":[{"line_number":145,"context_line":"    def test_get_v2_catalog_ignores_endpoints_with_invalid_urls(self):"},{"line_number":146,"context_line":"        user_id \u003d uuid.uuid4().hex"},{"line_number":147,"context_line":"        # If the URL has no \u0027tenant_id\u0027 to substitute, we will skip the"},{"line_number":148,"context_line":"        # endpoint which contains this kind of URL."},{"line_number":149,"context_line":"        catalog_ref \u003d self.catalog_api.get_catalog(user_id, tenant_id\u003dNone)"},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"        expected \u003d self.DEFAULT_FIXTURE.copy()"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ad0253b_dbbe0bd4","line":148,"in_reply_to":"7ad32947_90d3a538","updated":"2015-04-28 16:26:50.000000000","message":"As previous.  I\u0027ve made the message cover the situation more fully.  It\u0027s a bit chatty but should be fairly clear as to what is cause, what is consequence.","commit_id":"0a5571dd7781e3a0655650bb55ebe2f5c0ded27b"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def test_get_catalog(self):"},{"line_number":64,"context_line":"        catalog_ref \u003d self.catalog_api.get_catalog(\u0027foo\u0027, \u0027bar\u0027)"},{"line_number":65,"context_line":"        self.assertDictEqual(self.DEFAULT_FIXTURE, catalog_ref)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def test_catalog_ignored_malformed_urls(self):"},{"line_number":68,"context_line":"        # both endpoints are in the catalog"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_7774c035","line":65,"updated":"2015-07-30 09:28:33.000000000","message":"Please fix it in a separate commit","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        self.skipTest(\"Templated backend doesn\u0027t have disabled endpoints\")"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    def assert_v3_catalogs_equal(self, expected, observed):"},{"line_number":86,"context_line":"        self.assertEqual(len(expected), len(observed))"},{"line_number":87,"context_line":"        for e, o in zip(sorted(expected), sorted(observed)):"},{"line_number":88,"context_line":"            expected_endpoints \u003d e.pop(\u0027endpoints\u0027)"},{"line_number":89,"context_line":"            observed_endpoints \u003d o.pop(\u0027endpoints\u0027)"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_97714c47","line":86,"updated":"2015-07-30 09:28:33.000000000","message":"Please fix it in a separate commit","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"},{"author":{"_account_id":13478,"name":"Boris Bobrov","email":"b.bobrov@sap.com","username":"bbobrov"},"change_message_id":"978cff57d3c231248449beea26c6823bc9fcdd17","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        # So a service that contains only endpoints requiring tenant_id to be"},{"line_number":132,"context_line":"        # formatted will be omitted from the catalog in the absence of a"},{"line_number":133,"context_line":"        # tenant_id.  So there should only be one service in the expected"},{"line_number":134,"context_line":"        # catalog."},{"line_number":135,"context_line":"        catalog_ref \u003d self.catalog_api.get_v3_catalog(user_id, tenant_id\u003dNone)"},{"line_number":136,"context_line":"        exp_catalog \u003d ["},{"line_number":137,"context_line":"            {\u0027endpoints\u0027: ["}],"source_content_type":"text/x-python","patch_set":14,"id":"3a50d1a3_f7e450e1","line":134,"updated":"2015-07-30 09:28:33.000000000","message":"Please fix it in a separate commit","commit_id":"8853f89a50b3adce328e15aee20f04fba961b2f9"}]}
