Open Bug 2021067 Opened 25 days ago Updated 11 days ago

Buffer logs during wdspec tests and flush only on test failure

Categories

(Remote Protocol :: Agent, task, P2)

task
Points:
3

Tracking

(Not tracked)

People

(Reporter: jdescottes, Unassigned)

References

Details

(Whiteboard: [webdriver:m20])

Attachments

(2 files)

See Bug 2020914.

The logs created by wdspec tests are too big, we should buffer and only flush on failure.

Assignee: nobody → jdescottes
Status: NEW → ASSIGNED

One thing we should make sure is that all logging is buffered so that when we write it out for a failing test that the logs from Remote Agent and Firefox are still intersected and at the correct positions. Otherwise it would make it quite hard to match up our code.

(In reply to Henrik Skupin [:whimboo][⌚️UTC+1] from comment #2)

One thing we should make sure is that all logging is buffered so that when we write it out for a failing test that the logs from Remote Agent and Firefox are still intersected and at the correct positions. Otherwise it would make it quite hard to match up our code.

Off the top of my head I don't know if we can achieve this?
My goal was rather to try to log only the relevant test logs. So if a subtest failed, flush only that, and as close as possible to the failure itself.
Sounds like we would need fully synced logs with two separate buffers, I'm not sure how we can do this. Maybe you have a suggestion on how to tackle that?

Flags: needinfo?(hskupin)
Points: --- → 3
Priority: -- → P2
Whiteboard: [webdriver:m20]

As discussed in the meeting on Monday it would be good to have a try build with some failures forced in some of the tests. If possible lets as well set some MOZ_LOG like BCWebProgress:5 so that we can see how the output of the buffered logs look like. Based on that outcome lets see what the next steps could be.

Flags: needinfo?(hskupin) → needinfo?(jdescottes)

(just unassigning as this is for next milestone)

Assignee: jdescottes → nobody
Status: ASSIGNED → NEW

I had two variants of this patch.

The one uploaded on phab right now attempts to only buffer the logs for a subtest and flush only that - but it didn't seem to work as expected.
The previous version was buffering and flushing per test file, and that seems to work, but of course it makes it extra hard to find the relevant logs for the specific subtest which failed.

One example is https://treeherder.mozilla.org/logviewer?job_id=551858352&repo=try&task=TqU8lejFTXyQ1U31e8v9Ig.0&lineNumber=9990

(will attach the log here as well as a backup)

Flags: needinfo?(jdescottes)
Attached file live_backing.log

(In reply to Julian Descottes [:jdescottes] from comment #6)

The one uploaded on phab right now attempts to only buffer the logs for a subtest and flush only that - but it didn't seem to work as expected.
The previous version was buffering and flushing per test file, and that seems to work, but of course it makes it extra hard to find the relevant logs for the specific subtest which failed.

One example is https://treeherder.mozilla.org/logviewer?job_id=551858352&repo=try&task=TqU8lejFTXyQ1U31e8v9Ig.0&lineNumber=9990

Is that example for the current version of the patch on phab or the previous one?

previous one.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: