browser-perf
browser-perf copied to clipboard
Do not make an extra call to fetch logs
This seems to cause an issue with the chromedriver.
In regards to this comment. After some more stumbling around and googling I tracked down this issue which hints at multiple calls to performance logs leaves out trace info. Turns out there is a call to fetch the performance logs prior to setting up the log stream. I removed this call and got the tracing info.
I ran the unit tests after this change and did not see a negative impact. I'm not sure if there is something I'm missing that requires this call.
@brandonaaron - Thanks a lot for the PR. The extra call I was making was more to flush the logs before we start collecting them for the time range we care about. Thats why we have this. If we do not see any tracing data, that is probably because between the time this flush happens, and the time our actions happen to get the next log flush, there were no events generated. Could you share your sample usage and the website ?
@axemclion I threw together a repository with two test cases and their output. I just used the same url that is used in the unit tests. One is using master and the other is using this pull request (both are modified locally to have the line uncommented to generate _perflog.json).
@axemclion Any more thoughts on this?