)]}'
{"keystoneauth1/identity/base.py":[{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"b140dee50ad04b69623655c6fe7cf87839ef8bbd","unresolved":false,"context_lines":[{"line_number":239,"context_line":""},{"line_number":240,"context_line":"        try:"},{"line_number":241,"context_line":"            disc \u003d self.get_discovery(session, vers_url, authenticated\u003dFalse,"},{"line_number":242,"context_line":"                                      cache\u003dself._discovery_cache)"},{"line_number":243,"context_line":"        except (exceptions.DiscoveryFailure,"},{"line_number":244,"context_line":"                exceptions.HttpError,"},{"line_number":245,"context_line":"                exceptions.ConnectionError):"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_d4e37ad8","line":242,"range":{"start_line":242,"start_character":38,"end_line":242,"end_character":65},"updated":"2017-06-24 20:02:32.000000000","message":"why is it necessary to pass this cache here too?\n\nthe get_discovery call already looks into session.auth._discovery_cache","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c595e38067778c064514e2a3d7a1ab5a8ca6a355","unresolved":false,"context_lines":[{"line_number":239,"context_line":""},{"line_number":240,"context_line":"        try:"},{"line_number":241,"context_line":"            disc \u003d self.get_discovery(session, vers_url, authenticated\u003dFalse,"},{"line_number":242,"context_line":"                                      cache\u003dself._discovery_cache)"},{"line_number":243,"context_line":"        except (exceptions.DiscoveryFailure,"},{"line_number":244,"context_line":"                exceptions.HttpError,"},{"line_number":245,"context_line":"                exceptions.ConnectionError):"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_11a33fb4","line":242,"range":{"start_line":242,"start_character":38,"end_line":242,"end_character":65},"in_reply_to":"5f201791_d4e37ad8","updated":"2017-06-25 18:12:18.000000000","message":"the current get_discovery code is considering the session cache and the session\u0027s auth plugin cache","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"b140dee50ad04b69623655c6fe7cf87839ef8bbd","unresolved":false,"context_lines":[{"line_number":362,"context_line":"                                   (optional) Defaults to None (use a token"},{"line_number":363,"context_line":"                                   if a plugin is installed)."},{"line_number":364,"context_line":"        :param dict cache: A dict to be used for caching results, in addition"},{"line_number":365,"context_line":"                                   to caching them on the Session."},{"line_number":366,"context_line":"                                   (optional) Defaults to None."},{"line_number":367,"context_line":""},{"line_number":368,"context_line":"        :raises keystoneauth1.exceptions.discovery.DiscoveryFailure:"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_74cdc664","line":365,"updated":"2017-06-24 20:02:32.000000000","message":"(nit) indentation here should be a bit back","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c595e38067778c064514e2a3d7a1ab5a8ca6a355","unresolved":false,"context_lines":[{"line_number":362,"context_line":"                                   (optional) Defaults to None (use a token"},{"line_number":363,"context_line":"                                   if a plugin is installed)."},{"line_number":364,"context_line":"        :param dict cache: A dict to be used for caching results, in addition"},{"line_number":365,"context_line":"                                   to caching them on the Session."},{"line_number":366,"context_line":"                                   (optional) Defaults to None."},{"line_number":367,"context_line":""},{"line_number":368,"context_line":"        :raises keystoneauth1.exceptions.discovery.DiscoveryFailure:"}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_d1b38709","line":365,"in_reply_to":"5f201791_74cdc664","updated":"2017-06-25 18:12:18.000000000","message":"Done","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"b140dee50ad04b69623655c6fe7cf87839ef8bbd","unresolved":false,"context_lines":[{"line_number":387,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":388,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        # Finally check the auth cache associated with the Session."},{"line_number":391,"context_line":"        if session.auth:"},{"line_number":392,"context_line":"            caches.append(session.auth._discovery_cache)"},{"line_number":393,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_34750e33","line":390,"range":{"start_line":390,"start_character":59,"end_line":390,"end_character":66},"updated":"2017-06-24 20:02:32.000000000","message":"auth plugin","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c595e38067778c064514e2a3d7a1ab5a8ca6a355","unresolved":false,"context_lines":[{"line_number":387,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":388,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        # Finally check the auth cache associated with the Session."},{"line_number":391,"context_line":"        if session.auth:"},{"line_number":392,"context_line":"            caches.append(session.auth._discovery_cache)"},{"line_number":393,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_71cef382","line":390,"range":{"start_line":390,"start_character":59,"end_line":390,"end_character":66},"in_reply_to":"5f201791_34750e33","updated":"2017-06-25 18:12:18.000000000","message":"No, this is the cache of the auth plugin associated with the Session.","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"dcd01f9c5ed4b423abddf240434ebd446b44aed0","unresolved":false,"context_lines":[{"line_number":385,"context_line":"        # provided by the user at Session creation time."},{"line_number":386,"context_line":"        if not hasattr(session, \u0027_discovery_cache\u0027):"},{"line_number":387,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":388,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":389,"context_line":""},{"line_number":390,"context_line":"        # Finally check the cache of the plugin associated with the Session."},{"line_number":391,"context_line":"        if session.auth:"},{"line_number":392,"context_line":"            caches.append(session.auth._discovery_cache)"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"        for cache in caches:"},{"line_number":395,"context_line":"            disc \u003d cache.get(url)"}],"source_content_type":"text/x-python","patch_set":2,"id":"5f201791_31999b78","line":392,"range":{"start_line":388,"start_character":0,"end_line":392,"end_character":56},"updated":"2017-06-25 18:18:12.000000000","message":"the logic in this method changed with this. previously it was considering self._discovery_cache and session._discovery_cache\n\nnow it\u0027s using session._discovery_cache and session.auth._discovery_cache, thus self._discovery_cache needs to be explicitly passed into the call in L241-242\n\nwe are changing its default behavior (even if the behavior of get_endpoint_data is kept)\n\nThe solution I propose here is:\n1) use session._discovery_cache and self._discovery_cache within this method, as pass session.auth._discovery_cache in the call in L241-242 (since that is the new thing being added here)\n\n2) consider all 3 here in this method (session.auth._discovery_cache, session._discovery_cache and self._discovery_cache), in addition to a 4th optional cache that can be provided to this method. I just don\u0027t know if that would be interesting/useful to have","commit_id":"1b0dca3cdf7f41d96b1d416cf5593bc3e4f40023"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ff98f906e321b77d482a375dd883ad8018121ea","unresolved":false,"context_lines":[{"line_number":368,"context_line":""},{"line_number":369,"context_line":"        :returns: A discovery object with the results of looking up that URL."},{"line_number":370,"context_line":"        \"\"\""},{"line_number":371,"context_line":"        # There are between one and three different caches. The user may have"},{"line_number":372,"context_line":"        # passed one in. There is definitely one on the session, and there is"},{"line_number":373,"context_line":"        # one on the auth plugin if the Session has an auth plugin."},{"line_number":374,"context_line":"        caches \u003d []"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_61684b86","line":371,"range":{"start_line":371,"start_character":36,"end_line":371,"end_character":51},"updated":"2017-06-26 14:28:28.000000000","message":"actually there may have 2 as of this patch. I will still look at the patches following this one, and if we don\u0027t add more, I will fix up this comment","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"376cce7c64c6e49a3b2c012284b7add7386e111a","unresolved":false,"context_lines":[{"line_number":376,"context_line":"        # If the session has a cache, check it first, since it could have been"},{"line_number":377,"context_line":"        # provided by the user at Session creation time."},{"line_number":378,"context_line":"        if not hasattr(session, \u0027_discovery_cache\u0027):"},{"line_number":379,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":380,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        # Check the auth cache"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_44c33339","line":379,"updated":"2017-06-25 23:45:58.000000000","message":"i know the old way does this, but if there is no attribute on the session i\u0027d probably just skip it. This would be a weird scenario and it probably doesn\u0027t make sense to set it.","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"},{"author":{"_account_id":2,"name":"Monty Taylor","email":"mordred@inaugust.com","username":"mordred"},"change_message_id":"3cb79dffeee06768985d0bef3d4dc6616f11438d","unresolved":false,"context_lines":[{"line_number":376,"context_line":"        # If the session has a cache, check it first, since it could have been"},{"line_number":377,"context_line":"        # provided by the user at Session creation time."},{"line_number":378,"context_line":"        if not hasattr(session, \u0027_discovery_cache\u0027):"},{"line_number":379,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":380,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        # Check the auth cache"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_c4e4e3e2","line":379,"in_reply_to":"5f201791_44c33339","updated":"2017-06-25 23:49:38.000000000","message":"Nod - certainly makes sense. I can follow up with that.","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ff98f906e321b77d482a375dd883ad8018121ea","unresolved":false,"context_lines":[{"line_number":376,"context_line":"        # If the session has a cache, check it first, since it could have been"},{"line_number":377,"context_line":"        # provided by the user at Session creation time."},{"line_number":378,"context_line":"        if not hasattr(session, \u0027_discovery_cache\u0027):"},{"line_number":379,"context_line":"            session._discovery_cache \u003d {}"},{"line_number":380,"context_line":"        caches.append(session._discovery_cache)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        # Check the auth cache"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_a17c231f","line":379,"in_reply_to":"5f201791_c4e4e3e2","updated":"2017-06-26 14:28:28.000000000","message":"and it will always have I guess, since we\u0027ve set it in the session constructor to {} if no cache is passed in","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"}],"keystoneauth1/session.py":[{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"b1316bf71123f71dc86ab86bec247ee2a15775ae","unresolved":false,"context_lines":[{"line_number":223,"context_line":"                                       of the communication process."},{"line_number":224,"context_line":"    :param dict discovery_cache: A dict to be used for caching of discovery"},{"line_number":225,"context_line":"                                 information. This is normally managed"},{"line_number":226,"context_line":"                                 transparently, but if the user wants to"},{"line_number":227,"context_line":"                                 share a single cache across multiple sessions"},{"line_number":228,"context_line":"                                 that do not share an auth plugin, it can"},{"line_number":229,"context_line":"                                 be provided here. (optional, defaults to"},{"line_number":230,"context_line":"                                 None which means automatically manage)"},{"line_number":231,"context_line":"    \"\"\""},{"line_number":232,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"5f201791_b4323e5d","line":229,"range":{"start_line":226,"start_character":48,"end_line":229,"end_character":50},"updated":"2017-06-24 20:17:48.000000000","message":"we should add a test for this","commit_id":"757548483357350e0de823749af893d1bf9062f6"},{"author":{"_account_id":7191,"name":"Jamie Lennox","email":"jamielennox@gmail.com","username":"jamielennox"},"change_message_id":"376cce7c64c6e49a3b2c012284b7add7386e111a","unresolved":false,"context_lines":[{"line_number":227,"context_line":"                                 share a single cache across multiple sessions"},{"line_number":228,"context_line":"                                 that do not share an auth plugin, it can"},{"line_number":229,"context_line":"                                 be provided here. (optional, defaults to"},{"line_number":230,"context_line":"                                 None which means automatically manage)"},{"line_number":231,"context_line":"    \"\"\""},{"line_number":232,"context_line":""},{"line_number":233,"context_line":"    user_agent \u003d None"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_24a717aa","line":230,"updated":"2017-06-25 23:45:58.000000000","message":"Why do you have so many sessions?","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"},{"author":{"_account_id":2,"name":"Monty Taylor","email":"mordred@inaugust.com","username":"mordred"},"change_message_id":"3cb79dffeee06768985d0bef3d4dc6616f11438d","unresolved":false,"context_lines":[{"line_number":227,"context_line":"                                 share a single cache across multiple sessions"},{"line_number":228,"context_line":"                                 that do not share an auth plugin, it can"},{"line_number":229,"context_line":"                                 be provided here. (optional, defaults to"},{"line_number":230,"context_line":"                                 None which means automatically manage)"},{"line_number":231,"context_line":"    \"\"\""},{"line_number":232,"context_line":""},{"line_number":233,"context_line":"    user_agent \u003d None"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_44d8d31c","line":230,"in_reply_to":"5f201791_24a717aa","updated":"2017-06-25 23:49:38.000000000","message":"Long-lived programs that talk to OpenStack via potentially more than one account? So like, possibly heat/nova (although not sure if there is a good long-lived lifecycle point there) or oaktree.","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"}],"keystoneauth1/tests/unit/identity/test_identity_common.py":[{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ff98f906e321b77d482a375dd883ad8018121ea","unresolved":false,"context_lines":[{"line_number":190,"context_line":"            self.assertEqual(200, resp.status_code)"},{"line_number":191,"context_line":"            self.assertEqual(body, resp.text)"},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"    def test_discovery_uses_session_plugin_cache(self):"},{"line_number":194,"context_line":"        # register responses such that if the discovery URL is hit more than"},{"line_number":195,"context_line":"        # once then the response will be invalid and not point to COMPUTE_ADMIN"},{"line_number":196,"context_line":"        resps \u003d [{\u0027json\u0027: self.TEST_DISCOVERY}, {\u0027status_code\u0027: 500}]"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f201791_21c3735f","line":193,"updated":"2017-06-26 14:28:28.000000000","message":"it is actually not using the session plugin cache. it is working because all the caches are being updated once the discovery is done/retrieved from one cache.\n\nI will fix this up in a follow-up patch","commit_id":"68e0fe51791a57e78289bdc070c9f127811d8544"}]}
