web-platform-tests / wpt

Test suites for Web platform specs — including WHATWG, W3C, and others
https://web-platform-tests.org/
Other
4.98k stars 3.09k forks source link

Add ./wpt run --verbose as an alias of --log-mach-level debug #7846

Open gsnedders opened 7 years ago

gsnedders commented 7 years ago

It's a pain that we use something non-standard here and not that memorable.

qiuzhong commented 5 years ago

If you don't mind, I'll take this issue.

qiuzhong commented 5 years ago

If --verbose as an alias of --log-mach-level debug, here are my thoughts to handle the options:

@gsnedders , what do you think?

jgraham commented 5 years ago

This won't work if implemented naively. If the logging is set to something other than mach then implying the --mach-log-level argument will just cause an error about mach logging not being enabled.

gsnedders commented 5 years ago

IMO, we should be trying to figure out what the current logger for stdout is (or should we go for all loggers?) and making that level debug.

qiuzhong commented 5 years ago

@gsnedders , do you mean --verbose should support all kinds of log formats (raw, unnitest, xunit, html, tbpl, grouped, errorsummy from the mozlog module code)? My understanding is that besides the mach format, it should also support all these formats. In other word, --verbose option should be the alias of other --log_*_level debug options automatically, not so specific.

Did I misunderstand your intention?

qiuzhong commented 5 years ago

@jgraham, please also make a clarification if I got you wrong.

jgraham commented 5 years ago

Yeah, I think you need to find a way to figure out which is going to be the stdout logger and set whatever option is required to make that verbose if it exists. This is probably better done in mozlog itself in https://searchfox.org/mozilla-central/source/testing/mozbase/mozlog/mozlog/commandline.py Note that file has an existing concept of verbose, which I think is different.