Skip to content

Use lake exe cache get to skip rebuilding Mathlib#7

Merged
Gabrielebattimelli merged 1 commit intomainfrom
add-agent-skill
Apr 23, 2026
Merged

Use lake exe cache get to skip rebuilding Mathlib#7
Gabrielebattimelli merged 1 commit intomainfrom
add-agent-skill

Conversation

@Gabrielebattimelli
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings April 23, 2026 08:19
@Gabrielebattimelli Gabrielebattimelli merged commit df802ad into main Apr 23, 2026
2 checks passed
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the weekly indexing GitHub Actions workflow to leverage Mathlib’s Lake cache mechanism so the pipeline can avoid rebuilding Mathlib when possible.

Changes:

  • Adds lake exe cache get before lake build in the PhysLib build step.
  • Reduces the PhysLib build step timeout from 90 minutes to 30 minutes.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

if: steps.check.outputs.has_changes == 'true'
run: cd physlib && lake build
timeout-minutes: 90
run: cd physlib && lake exe cache get && lake build
Copy link

Copilot AI Apr 23, 2026

Choose a reason for hiding this comment

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

The build step is now chained with &&, so any transient failure in lake exe cache get (network, cache server, missing artifact) will prevent lake build from running. If the intent is “use cache when available, otherwise fall back to building”, make cache get non-fatal (e.g., separate step or handle its exit code) so the workflow still proceeds to lake build.

Suggested change
run: cd physlib && lake exe cache get && lake build
run: |
cd physlib
lake exe cache get || echo "lake exe cache get failed; continuing with lake build"
lake build

Copilot uses AI. Check for mistakes.
run: cd physlib && lake build
timeout-minutes: 90
run: cd physlib && lake exe cache get && lake build
timeout-minutes: 30
Copy link

Copilot AI Apr 23, 2026

Choose a reason for hiding this comment

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

timeout-minutes was reduced from 90 to 30. If lake exe cache get is unavailable or the cache misses, the subsequent lake build may exceed 30 minutes and get killed even though it would succeed. Consider keeping a longer timeout (or making it conditional on cache-get success) to avoid flaky weekly runs.

Suggested change
timeout-minutes: 30
timeout-minutes: 90

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants