New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added an option to allow submitting test-perf result to perfherder #14147
Conversation
Heads up! This PR modifies the following files:
|
@@ -7,27 +7,21 @@ Servo Page Load Time Test | |||
|
|||
# Basic Usage | |||
|
|||
## Prepare the test runner | |||
If you want to run a performance test for your servo build. Simply go to the top-level servo directory and run `./mach test-perf`. The test result JOSN will be saved to `etc/ci/performance/output/`. You can compare two test results with the `test_differ.py` script. Run `python test_differ.py -h` for instructions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Fixing style,
"./mach test-perf
can be used to run a performance test on your servo build. The test result JSON will be saved to etc/ci/performance/output/
. You can then run python test_differ.py
to compare these two test results. Run python test_differ.py -h
for instructions."
* Run `prepare_manifest.sh` to transform the tp5n manifest to our format | ||
* Install the Python3 `treeherder-client` package. For example, to install it in a virtualenv: `python3 -m virtualenv venv; source venv/bin/activate; pip install "treeherder-client>=3.0.0"` | ||
# Setup for CI machine | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What should be done here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This H1 is for the subsections "For Servo" and "For Gecko", I'll change them to "CI for Servo" to make it clear.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, never mind 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But yeah, it could just be "CI for Servo"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few nits, looks like this will be useful!
@@ -34,4 +34,9 @@ pip install "treeherder-client>=3.0.0" | |||
mkdir -p servo | |||
mkdir -p output | |||
./git_log_to_json.sh > servo/revision.json && \ | |||
./test_all.sh --servo | |||
|
|||
if [[ "${1}" = "--submit" ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to guard this by checking the number of arguments before looking at any of their values.
@@ -34,4 +34,9 @@ pip install "treeherder-client>=3.0.0" | |||
mkdir -p servo | |||
mkdir -p output | |||
./git_log_to_json.sh > servo/revision.json && \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for the && \
at the end.
@@ -34,4 +34,9 @@ pip install "treeherder-client>=3.0.0" | |||
mkdir -p servo | |||
mkdir -p output |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need to make this output
dir? Add a comment or remove it.
return call(["bash", "test_perf.sh"], | ||
cmd = ["bash", "test_perf.sh"] | ||
if submit: | ||
cmd += ["--submit"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should check that the Treeherder environment variables are set if submit
is True before we actually run the command, to improve the user experience (e.g. if you don't read carefully).
c052aa1
to
0b59b8a
Compare
|
0b59b8a
to
4f377ac
Compare
@aneeshusa This is waiting on your review. |
@aneeshusa Since there is no major issue, and I need to land this ASAP, I'll ask @larsbergstrom for the final sign-off. Hope you don't mind! |
@bors-servo r=larsbergstrom,aneeshusa We can chat more in Hawaii if there are any follow-ups needed here :-) |
📌 Commit 4f377ac has been approved by |
…eshusa Added an option to allow submitting test-perf result to perfherder <!-- Please describe your changes on the following line: --> This patch enables us to run `./mach test-perf --submit` in CI to submit the result to perfherder. r? @aneeshusa --- <!-- 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 - [] These changes fix #__ (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [x] These changes do not require tests because too many manual setup required to test it <!-- 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/14147) <!-- Reviewable:end -->
💔 Test failed - linux-rel-wpt |
☔ The latest upstream changes (presumably #14194) made this pull request unmergeable. Please resolve the merge conflicts. |
4f377ac
to
ddd0322
Compare
The conflict is in the README file, so no big deal. The test seems to be some network error while running |
@bors-servo r=larsbergstrom,aneeshusa |
📌 Commit ddd0322 has been approved by |
…eshusa Added an option to allow submitting test-perf result to perfherder <!-- Please describe your changes on the following line: --> This patch enables us to run `./mach test-perf --submit` in CI to submit the result to perfherder. r? @aneeshusa --- <!-- 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 - [] These changes fix #__ (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [x] These changes do not require tests because too many manual setup required to test it <!-- 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/14147) <!-- Reviewable:end -->
☀️ Test successful - arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css, mac-rel-wpt1, mac-rel-wpt2, windows-dev |
This patch enables us to run
./mach test-perf --submit
in CI to submit the result to perfherder. r? @aneeshusa./mach build -d
does not report any errors./mach test-tidy
does not report any errorsThis change is