https://bugzilla.novell.com/show_bug.cgi?id=379074 User mmarek@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=379074#c7 --- Comment #7 from Michal Marek <mmarek@novell.com> 2008-04-28 12:39:47 MST --- (In reply to comment #6 from Marcus Hüwe)
I don't know if it would really make the code more complex - basically we just replace the "print + sys.exit(n)" statements with "raise OSCError("meaningful message"...). But if we do so we also have to ensure that our OSCError exceptions are catched appropriately which will result in more lines of code. In theory it would look like this: try: some_osc_cmds except OSCError, e: print >>sys.stderr, e.msg sys.exit(1)
In the osc command line program, you only need to handle the OSCError exceptions in osc-wrapper.py. No noticeable code growth :-). -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.