-
Notifications
You must be signed in to change notification settings - Fork 210
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
Add /job_groups/id/build_results API route #5433
Conversation
f5d9a23
to
11c5e51
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5433 +/- ##
=======================================
Coverage 98.37% 98.38%
=======================================
Files 389 389
Lines 37769 37827 +58
=======================================
+ Hits 37157 37215 +58
Misses 612 612 ☔ View full report in Codecov by Sentry. |
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.
+1
So the
EDIT: Looks like this would actually already work. |
Issue: https://progress.opensuse.org/issues/152939 I moved `_map_tags_into_build` into the `compute_build_results()` function. The command lime to get the last "published" build would look like this: openqa-cli api job_groups/1/build_results only_tagged=1 limit_builds=1 \ | jq -r '[.build_results[] | select(.tag.description=="published") | select(.version=="Tumbleweed") | .build ][0]' To only get the latest build: openqa-cli api job_groups/1/build_results limit_builds=1 | jq -r '[.build_results[] | .build ][0]'
11c5e51
to
2dd03be
Compare
I edited the commit message to include |
Two tests from this are failing in Fedora, for some reason. |
Huh, this "fixes" it:
...weird. |
Hmm, this feels very fuzzy. If I make the code into this:
and then make the check this:
it passes, not surprisingly. But it also passes if I make the check this:
so it "is" both |
Issue: https://progress.opensuse.org/issues/152939
I moved
_map_tags_into_build
into thecompute_build_results()
function.The command lime to get the last "published" build would look like this:
To only get the latest build:
Only normal groups are supported, not parent groups, to keep it simple. I can go though our logs to see if the group_overview.json is ever called for parent groups.
I am seeing a problem with the documentation display of the new function when getting a 404. The documentation for the new function is displayed for
+/job_groups/<group_id:num>/jobs GET
as well as+/job_groups/<group_id:num>/build_results
.Maybe a bug in how Mojolicious renders the pod. I can't see anything wrong there.
Also I found a misdocumented route. I will open a seperate PR.
Still need to document this somewhere.