prasannakumar123 / munki

Automatically exported from code.google.com/p/munki
Other
0 stars 0 forks source link

Catch EOFError and not just KeyboardInterrupt in manifestutil #352

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
ctrl+d throws a traceback in manifestutil in interactive mode.

except EOFError added here:

https://code.google.com/r/ryanmanly-munki/source/detail?r=292aed499629d74c44226b
9415ce37732df5a8fb

Original issue reported on code.google.com by ryan.manly@gmail.com on 17 Jul 2014 at 5:59

GoogleCodeExporter commented 8 years ago
I don't have rights to comment directly in your clone, but I think it would be 
better to condense:

            except KeyboardInterrupt:
                print # so we finish off the raw_input line
                cleanupAndExit(0)
            except EOFError:
                print # so we finish off the raw_input line
                cleanupAndExit(0)

to

            except (KeyboardInterrupt, EOFError):
                print # so we finish off the raw_input line
                cleanupAndExit(0)

Original comment by gregnea...@mac.com on 17 Jul 2014 at 6:15

GoogleCodeExporter commented 8 years ago
Ryan: if you make the change, I will merge. Or I can just make the change 
myself. Your call.

Original comment by greg.nea...@disneyanimation.com on 22 Jul 2014 at 5:11

GoogleCodeExporter commented 8 years ago
I decided to just implement the fix and close the issue.
https://code.google.com/p/munki/source/detail?r=bb4fd416f8fe55999f3b51fa7c735029
d30ec4fa&name=Munki2

Original comment by gregnea...@mac.com on 25 Jul 2014 at 10:23