[Webkit-unassigned] [Bug 36504] Add a flag to run_webkit_tests to control saving crashing stacks

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Mar 25 16:28:15 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=36504





--- Comment #4 from Dirk Pranke <dpranke at chromium.org>  2010-03-25 16:28:15 PST ---
(From update of attachment 51453)
> +    option_parser.add_option("", "--nosave-crash-stack", action="store_true",
> +                             default=False,
> +                             help="Don't save crashing stack traces to disk")

Okay, from poking around in the optparse documentation, it looks like perhaps
the "clean" way to handle boolean flags would be
to have:

option_parser.add_option("", "--save-crash-stack", action="store_true",
default="True",
                         help="save crashing stack traces to disk")
option_parser.add_option("", "--nosave-crash-stack", value="save_crash_stack",
                         action="store_false", help="don't save crashing stack
traces to disk")

and then test against if options.save_crash_stack (to avoid the double
negative). Note the use of the 'value="xxx" named argument in the second line
to tell the parser that the two flags affect the same field.

-- Dirk

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list