Skip to content
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

base rebuild order on last build attempt, not rustc date #2660

Merged
merged 1 commit into from
Nov 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

This file was deleted.

17 changes: 11 additions & 6 deletions src/build_queue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -698,19 +698,24 @@ pub async fn queue_rebuilds(
SELECT
c.name,
r.version,
max(b.rustc_nightly_date) as rustc_nightly_date

(
SELECT MAX(b.rustc_nightly_date)
FROM builds AS b
WHERE b.rid = r.id AND b.rustc_nightly_date IS NOT NULL
) AS rustc_nightly_date,
(
SELECT MAX(COALESCE(b.build_finished, b.build_started))
FROM builds AS b
WHERE b.rid = r.id
) AS last_build_attempt
FROM crates AS c
INNER JOIN releases AS r ON c.latest_version_id = r.id
INNER JOIN builds AS b ON r.id = b.rid

WHERE
r.rustdoc_status = TRUE

GROUP BY c.name, r.version
) as i
WHERE i.rustc_nightly_date < $1
ORDER BY i.rustc_nightly_date ASC
ORDER BY i.last_build_attempt ASC
LIMIT $2",
config
.rebuild_up_to_date
Expand Down
Loading