)]}'
{"novaclient/shell.py":[{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bd9b9750eeaf6452b9e849d52660d09ce98c3289","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            self.need_lookup \u003d False"},{"line_number":130,"context_line":"            self.real_action \u003d None"},{"line_number":131,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":132,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":133,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a7e1126_d387e3d5","line":130,"range":{"start_line":128,"start_character":0,"end_line":130,"end_character":35},"updated":"2015-12-17 00:43:48.000000000","message":"Do we really need this? I thought if real_action is None we would want to do the lookup in the parser unless we\u0027ve cached it","commit_id":"2649a44a81e5a700d053fcfb24086e0976878cd0"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"061c57e2ffc3eca9a920ef66bca2014de9d79c79","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            self.need_lookup \u003d False"},{"line_number":130,"context_line":"            self.real_action \u003d None"},{"line_number":131,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":132,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":133,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a7e1126_e3bc0208","line":130,"range":{"start_line":128,"start_character":0,"end_line":130,"end_character":35},"in_reply_to":"3a7e1126_d387e3d5","updated":"2015-12-18 19:29:42.000000000","message":"Nothing in novaclient currently needs this.  The idea here is for options that are deprecated because they no longer do anything; e.g., if the \"--all-tenants\" option became the default behavior, you\u0027d mark it as deprecated but set the \"real_action\" to \"nothing\".\n\nNote: \"nothing\" is distinct from real_action\u003dNone; it\u0027s essentially a new action string.  That\u0027s why this clause sets need_action to False.","commit_id":"2649a44a81e5a700d053fcfb24086e0976878cd0"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bd9b9750eeaf6452b9e849d52660d09ce98c3289","unresolved":false,"context_lines":[{"line_number":155,"context_line":"        \"\"\""},{"line_number":156,"context_line":""},{"line_number":157,"context_line":"        # If a lookup is needed, look up the action in the parser"},{"line_number":158,"context_line":"        if self.need_lookup is not False:"},{"line_number":159,"context_line":"            option_strings, dest, help, kwargs \u003d self.need_lookup"},{"line_number":160,"context_line":"            action_class \u003d parser._registry_get(\u0027action\u0027, self.real_action)"},{"line_number":161,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"3a7e1126_d313630c","line":158,"updated":"2015-12-17 00:43:48.000000000","message":"Could we get rid of the self.need_lookup variable by checking the type of self.real_action instead? It seems like if real_action is an Action, it\u0027s either been passed directly or it\u0027s been cached and we can just not do a lookup.\n\nUpon further inspection, I see need_lookup holds the Action class args too. Maybe it would be better to just call it \"real_action_args\" or something that describes it. So I would say change the name and don\u0027t use it as the check for whether to lookup","commit_id":"2649a44a81e5a700d053fcfb24086e0976878cd0"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"061c57e2ffc3eca9a920ef66bca2014de9d79c79","unresolved":false,"context_lines":[{"line_number":155,"context_line":"        \"\"\""},{"line_number":156,"context_line":""},{"line_number":157,"context_line":"        # If a lookup is needed, look up the action in the parser"},{"line_number":158,"context_line":"        if self.need_lookup is not False:"},{"line_number":159,"context_line":"            option_strings, dest, help, kwargs \u003d self.need_lookup"},{"line_number":160,"context_line":"            action_class \u003d parser._registry_get(\u0027action\u0027, self.real_action)"},{"line_number":161,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"3a7e1126_e353a2e0","line":158,"in_reply_to":"3a7e1126_d313630c","updated":"2015-12-18 19:29:42.000000000","message":"Name change sounds like a good idea; I\u0027ll do that for the next patchset.","commit_id":"2649a44a81e5a700d053fcfb24086e0976878cd0"},{"author":{"_account_id":6547,"name":"Andreas Jaeger","email":"jaegerandi@gmail.com","username":"jaegerandi"},"change_message_id":"86cffd29db85b0d1d838897b139a58191c7d9fd2","unresolved":false,"context_lines":[{"line_number":466,"context_line":"            \u0027--os_username\u0027,"},{"line_number":467,"context_line":"            action\u003dDeprecatedAction,"},{"line_number":468,"context_line":"            use\u003d_(\u0027use \"%s\"; this option will be removed \u0027"},{"line_number":469,"context_line":"                  \u0027in novaclient 3.1.0\u0027) % \u0027--os-username\u0027,"},{"line_number":470,"context_line":"            help\u003dargparse.SUPPRESS)"},{"line_number":471,"context_line":""},{"line_number":472,"context_line":"        parser.add_argument("}],"source_content_type":"text/x-python","patch_set":5,"id":"fa69d971_bf130b0d","line":469,"range":{"start_line":469,"start_character":38,"end_line":469,"end_character":40},"updated":"2015-12-29 20:01:29.000000000","message":"I suggest to end all these entries with \".\" since those are complete sentences.","commit_id":"4c7ae42af6720a23dd9b8110f158f3df8ff48bfc"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"fbd0beeacef7d8bff94b1dee368f344b6fa85cdf","unresolved":false,"context_lines":[{"line_number":466,"context_line":"            \u0027--os_username\u0027,"},{"line_number":467,"context_line":"            action\u003dDeprecatedAction,"},{"line_number":468,"context_line":"            use\u003d_(\u0027use \"%s\"; this option will be removed \u0027"},{"line_number":469,"context_line":"                  \u0027in novaclient 3.1.0\u0027) % \u0027--os-username\u0027,"},{"line_number":470,"context_line":"            help\u003dargparse.SUPPRESS)"},{"line_number":471,"context_line":""},{"line_number":472,"context_line":"        parser.add_argument("}],"source_content_type":"text/x-python","patch_set":5,"id":"fa69d971_f13697b3","line":469,"range":{"start_line":469,"start_character":38,"end_line":469,"end_character":40},"in_reply_to":"fa69d971_bf130b0d","updated":"2015-12-29 20:50:38.000000000","message":"Seems reasonable.  Done.","commit_id":"4c7ae42af6720a23dd9b8110f158f3df8ff48bfc"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"828823b70e07cc15b751b62f7b19f8322545c9ef","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            # NOTE(Vek): \"nothing\" is distinct from a real_action\u003dNone"},{"line_number":130,"context_line":"            # argument.  When real_action\u003dNone, the argparse default"},{"line_number":131,"context_line":"            # action of \"store\" is used; when real_action\u003d\u0027nothing\u0027,"},{"line_number":132,"context_line":"            # however, we explicitly inhibit doing anything with the"},{"line_number":133,"context_line":"            # option"},{"line_number":134,"context_line":"            self.real_action_args \u003d False"},{"line_number":135,"context_line":"            self.real_action \u003d None"},{"line_number":136,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":137,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":138,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":8,"id":"da6ed579_fa38753f","line":135,"range":{"start_line":128,"start_character":8,"end_line":135,"end_character":35},"updated":"2016-01-12 23:31:46.000000000","message":"I\u0027m not sure this makes sense. I had a look through the argparse source to see how the default action of \"store\" comes about and from what I can tell, there\u0027s no way to argparse.add_argument without an action (you have to at least get the \"store\" action). So why do we want to allow something here with DeprecatedAction that isn\u0027t possible to do with any other action through add_argument? I feel like we can just let the default be \"store\" and not have a \u0027nothing\u0027 option.\n\nIt just seems like if have a real \"do nothing\" option isn\u0027t possible with vanilla add_argument, I don\u0027t see anyone thinking to use real_action\u003d\u0027nothing\u0027 and all it does is make this code more confusing.","commit_id":"08c4b746b2b894a5cb178c762850a1730e1c636e"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"71971788e7ebf6d01ed9ccb86e4dc1bf88c07d0f","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            # NOTE(Vek): \"nothing\" is distinct from a real_action\u003dNone"},{"line_number":130,"context_line":"            # argument.  When real_action\u003dNone, the argparse default"},{"line_number":131,"context_line":"            # action of \"store\" is used; when real_action\u003d\u0027nothing\u0027,"},{"line_number":132,"context_line":"            # however, we explicitly inhibit doing anything with the"},{"line_number":133,"context_line":"            # option"},{"line_number":134,"context_line":"            self.real_action_args \u003d False"},{"line_number":135,"context_line":"            self.real_action \u003d None"},{"line_number":136,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":137,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":138,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":8,"id":"da6ed579_851c7ac2","line":135,"range":{"start_line":128,"start_character":8,"end_line":135,"end_character":35},"in_reply_to":"da6ed579_05af2a95","updated":"2016-01-13 00:03:54.000000000","message":"Let me try a hypothetical to explain the usage I\u0027m envisioning: say v1.0 of FancyApp is released with a command line option --wangle to turn on the experimental wangling behavior.  Now, sometime later, wangling is no longer experimental, and becomes the default behavior, so the --wangle option is no longer needed.  However, all FancyApp\u0027s users still have scripts using --wangle, so some sort of \"do nothing\" variant of the original --wangle option is necessary; otherwise, all their scripts would now break.  It doesn\u0027t have to do anything (other than emit a warning saying, \"You don\u0027t need --wangle!\"), but it still needs to be there.\n\nDoes that make it clearer what I\u0027m trying to do with this code?  As I say, nothing in novaclient right now needs it, and I\u0027m happy to just drop it if you want me to…","commit_id":"08c4b746b2b894a5cb178c762850a1730e1c636e"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"ab745fcc607f097d42041102d7b6c31f6967b2dd","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            # NOTE(Vek): \"nothing\" is distinct from a real_action\u003dNone"},{"line_number":130,"context_line":"            # argument.  When real_action\u003dNone, the argparse default"},{"line_number":131,"context_line":"            # action of \"store\" is used; when real_action\u003d\u0027nothing\u0027,"},{"line_number":132,"context_line":"            # however, we explicitly inhibit doing anything with the"},{"line_number":133,"context_line":"            # option"},{"line_number":134,"context_line":"            self.real_action_args \u003d False"},{"line_number":135,"context_line":"            self.real_action \u003d None"},{"line_number":136,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":137,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":138,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":8,"id":"da6ed579_05af2a95","line":135,"range":{"start_line":128,"start_character":8,"end_line":135,"end_character":35},"in_reply_to":"da6ed579_7a548520","updated":"2016-01-12 23:53:47.000000000","message":"Sorry, having trouble parsing the second sentence. The case where a deprecated option stays around after the option is made the default?\n\nI guess I\u0027m just thinking, a deprecated option is still an option that has to work and store something until it\u0027s removed and I didn\u0027t understand how and when it would be turned into a no-op.","commit_id":"08c4b746b2b894a5cb178c762850a1730e1c636e"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"aeba6e55206398fa7cad0df2502757c294a86d8d","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            # NOTE(Vek): \"nothing\" is distinct from a real_action\u003dNone"},{"line_number":130,"context_line":"            # argument.  When real_action\u003dNone, the argparse default"},{"line_number":131,"context_line":"            # action of \"store\" is used; when real_action\u003d\u0027nothing\u0027,"},{"line_number":132,"context_line":"            # however, we explicitly inhibit doing anything with the"},{"line_number":133,"context_line":"            # option"},{"line_number":134,"context_line":"            self.real_action_args \u003d False"},{"line_number":135,"context_line":"            self.real_action \u003d None"},{"line_number":136,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":137,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":138,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":8,"id":"da6ed579_c06ee095","line":135,"range":{"start_line":128,"start_character":8,"end_line":135,"end_character":35},"in_reply_to":"da6ed579_851c7ac2","updated":"2016-01-13 00:25:44.000000000","message":"Yes, very clear now, thanks! It seems reasonable to provide something for that scenario. I just couldn\u0027t think of how it would come up until you gave the example.","commit_id":"08c4b746b2b894a5cb178c762850a1730e1c636e"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"0e67be2d8145af434ed28f9025fdc204af3c27bb","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self.use \u003d use"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"        # Select the appropriate action"},{"line_number":128,"context_line":"        if real_action \u003d\u003d \u0027nothing\u0027:"},{"line_number":129,"context_line":"            # NOTE(Vek): \"nothing\" is distinct from a real_action\u003dNone"},{"line_number":130,"context_line":"            # argument.  When real_action\u003dNone, the argparse default"},{"line_number":131,"context_line":"            # action of \"store\" is used; when real_action\u003d\u0027nothing\u0027,"},{"line_number":132,"context_line":"            # however, we explicitly inhibit doing anything with the"},{"line_number":133,"context_line":"            # option"},{"line_number":134,"context_line":"            self.real_action_args \u003d False"},{"line_number":135,"context_line":"            self.real_action \u003d None"},{"line_number":136,"context_line":"        elif real_action is None or isinstance(real_action, six.string_types):"},{"line_number":137,"context_line":"            # Specified by string (or None); we have to have a parser"},{"line_number":138,"context_line":"            # to look up the actual action, so defer to later"}],"source_content_type":"text/x-python","patch_set":8,"id":"da6ed579_7a548520","line":135,"range":{"start_line":128,"start_character":8,"end_line":135,"end_character":35},"in_reply_to":"da6ed579_fa38753f","updated":"2016-01-12 23:40:43.000000000","message":"That\u0027s correct, but argparse was designed without the idea of a deprecated option.  I have definitely seen cases where a deprecated option has had to stay around even after the CLI it was for made that option the default, and that\u0027s what this code is trying to deal with.  Now, of course, this may just be my tendency toward YAGNI-type code, and as I say, nothing in novaclient needs this action, so if you want me to just drop this clause, I can do that.","commit_id":"08c4b746b2b894a5cb178c762850a1730e1c636e"}]}
