Skip to content

Bug 10452 - Page Load Time Test Runner - #11107

Merged
shinglyu merged 1 commit into
servo:masterfrom
shinglyu:servo-perf
Aug 8, 2016
Merged

shinglyu merged 1 commit into
servo:masterfrom
shinglyu:servo-perf

Conversation

@shinglyu

@shinglyu shinglyu commented May 10, 2016 •

Copy link
Copy Markdown
Contributor

This is a minimal test runner for bug #10452 .

The main entry point is test_all.sh, which will trigger runner.py (run the performance test), then run submit_to_perfherder.py (push performance data to perfherder)

There are also some utility script scattered around.

You can also check README.md for detail.


This change is Reviewable

@highfive

Copy link
Copy Markdown

Heads up! This PR modifies the following files:

  • @aneeshusa: etc/ci/performance/git_log_to_json.sh, etc/ci/performance/master.cfg, etc/ci/performance/credential.json.example, etc/ci/performance/test_all.sh, etc/ci/performance/test_submit_to_perfherder.py, etc/ci/performance/prepare_manifest.sh, etc/ci/performance/.gitignore, etc/ci/performance/test_runner.py, etc/ci/performance/submit_to_perfherder.py, etc/ci/performance/README.md, etc/ci/performance/user-agent-js/01.perf-timing.js, etc/ci/performance/runner.py, etc/ci/performance/user-agent-js/02.timeout.js

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label May 10, 2016
@shinglyu

Copy link
Copy Markdown
Contributor Author

cc @autrilla

Comment thread etc/ci/performance/runner.py Outdated
print("Running test:")
print(test_cmd)
print("Timeout:{}".format(timeout))
log = ""

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why aren't you simply returning subprocess.check_output here?

@aneeshusa

Copy link
Copy Markdown
Contributor

I skimmed this and I'd like to make some review comments in a few days when my final projects are turned in.

@highfive

Copy link
Copy Markdown

New code was committed to pull request.

@shinglyu

Copy link
Copy Markdown
Contributor Author

@autrilla I'm updating the README and runner in this patch. I might now merge it back to the servo-perf repo right now, so check here for updates.

@highfive

Copy link
Copy Markdown

New code was committed to pull request.

@shinglyu

Copy link
Copy Markdown
Contributor Author

@aneeshusa r?

@larsbergstrom

Copy link
Copy Markdown
Contributor

@aneeshusa Do you have feedback on this? Otherwise, I'm going to land it and we can follow up with any changes you'd like.

@jdm jdm added the S-fails-tidy `./mach test-tidy` reported errors. label May 27, 2016
Comment thread etc/ci/performance/.gitignore Outdated
@@ -0,0 +1,9 @@
page_load_test/*

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to include this file here.

@aneeshusa

Copy link
Copy Markdown
Contributor

Sorry about the long delay. Can you update this to include your new changes from the servo-perf repository?

Comment thread etc/ci/performance/runner.py Outdated
except subprocess.CalledProcessError as e:
print("Unexpected Fail:")
print(e)
print("You man want to re-run the test manually:\n{}".format(test_cmd))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spelling: may

@aneeshusa

Copy link
Copy Markdown
Contributor

It looks like some of my review comments have already been taken care of in the servo-perf repo (like replacing median with the stdlib version), so I'll hold off on more review until you update this.

@larsbergstrom larsbergstrom added S-needs-code-changes Changes have not yet been made that were requested by a reviewer. and removed S-awaiting-review There is new code that needs to be reviewed. labels Jun 29, 2016
@highfive highfive removed the S-needs-code-changes Changes have not yet been made that were requested by a reviewer. label Jun 30, 2016
Comment thread etc/ci/performance/test_all.sh Outdated

echo "Running tests"
python3 runner.py --runs 3 $MANIFEST $PERF_FILE
python3 runner.py $engine --runs 3 $MANIFEST $PERF_FILE

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Running runner.py twice with different arguments seems like a bug.

@aneeshusa

Copy link
Copy Markdown
Contributor

I think a rebase (you can squash as well) will take care of the tidy failure. Also, take a look at the linting being added in #12295 and please make sure the scripts conform to it as I expect that to be merged soon.

Comment thread etc/ci/performance/test_all.sh Outdated
;;
esac

source venv/bin/activate

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When we run this on the builders we'll likely either already be inside the virtualenv from mach or have system-wide-installed libraries available, so please remove this line. Probably would be good to update the docs to mention this.

@shinglyu shinglyu mentioned this pull request Jul 29, 2016
3 tasks done
bors-servo pushed a commit that referenced this pull request Jul 29, 2016
Add python3 licence check template

<!-- Please describe your changes on the following line: -->

Add a python3 license template. #11107 uses python3 exclusively so we need this.
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes do not require tests because covered by test-tidy self test

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12650)
<!-- Reviewable:end -->
@metajack

Copy link
Copy Markdown
Collaborator

Why is python3 required for this? Can't we use python2.7 with from future imports? I really don't want to require multiple versions of python for our build.

@shinglyu

shinglyu commented Aug 1, 2016

Copy link
Copy Markdown
Contributor Author

@metajack I don't expect to run this in the build process in the near future. Checking this into the tree is for people to run on their own computer, so I believe this won't impact our CI very much. We actually migrated from 2.7 to 3 because of previous review comments, so may we land this first and discuss the CI integration later?

@metajack

metajack commented Aug 1, 2016

Copy link
Copy Markdown
Collaborator

@shinglyu That sounds fine.

@larsbergstrom

Copy link
Copy Markdown
Contributor

It looks to me like this has been fully reviewed and is ready to go except for license issues reported by tidy:

./etc/ci/performance/runner.py:1: incorrect license

./etc/ci/performance/submit_to_perfherder.py:1: incorrect license

./etc/ci/performance/test_runner.py:1: incorrect license

./etc/ci/performance/test_submit_to_perfherder.py:1: incorrect license

@shinglyu

shinglyu commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

Just rebased to the latest master and clean up all the tidy errors.

@shinglyu
shinglyu merged commit 7ed9134 into servo:master Aug 8, 2016
@KiChjang

KiChjang commented Aug 8, 2016

Copy link
Copy Markdown
Contributor

@shinglyu Why did you manually merge this?

@shinglyu

shinglyu commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

Oh no! I subconsciously click the merge button. Is there any way to revert this?

@shinglyu

shinglyu commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

I'm so sorry, I hope I didn't break any Ci stuff.

@metajack

metajack commented Aug 8, 2016

Copy link
Copy Markdown
Collaborator

If master is still green, I think it's fine to let this stand. If we have broken the three we should revert this or quickly fix in a followup.

@shinglyu

shinglyu commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

This does not touch any servo code, its some self-contained python code in the /etc/ci directory, so I believe the tree is still green.

@metajack

metajack commented Aug 8, 2016

Copy link
Copy Markdown
Collaborator

Ok, no harm done then since this had already been reviewed.

We're looking into ways to prevent accidental merges like this. It seems GitHub may have added some new things since we last tried to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-review There is new code that needs to be reviewed. S-fails-tidy `./mach test-tidy` reported errors.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants