Skip to content

chore(ci): replace local uv setup action with astral-sh/setup-uv@v6#8491

Merged
ogabrielluiz merged 4 commits into
mainfrom
fix-uv-caching-again
Jun 11, 2025
Merged

chore(ci): replace local uv setup action with astral-sh/setup-uv@v6#8491
ogabrielluiz merged 4 commits into
mainfrom
fix-uv-caching-again

Conversation

@ogabrielluiz
Copy link
Copy Markdown
Contributor

@ogabrielluiz ogabrielluiz commented Jun 11, 2025

Summary by CodeRabbit

  • Chores
    • Updated all workflows to use an external environment setup action with improved caching, replacing the previous local custom action.
    • Enabled caching based on the presence of the uv.lock file for more efficient workflow runs.
    • Removed the local setup action as it is no longer needed.

@dosubot dosubot Bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Jun 11, 2025
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jun 11, 2025

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Walkthrough

This change removes the local composite GitHub Action for setting up "uv" and updates all workflow files to use the external astral-sh/setup-uv@v6 action instead. The new usage includes parameters for enabling cache and specifying the cache dependency file, standardizing environment setup across workflows.

Changes

Files/Groups Change Summary
.github/actions/setup-uv/action.yml Deleted the local composite action for setting up "uv".
.github/workflows/codeflash.yml
.github/workflows/docker-build.yml
.github/workflows/integration_tests.yml
.github/workflows/lint-py.yml
.github/workflows/nightly_build.yml
.github/workflows/python_test.yml
.github/workflows/release.yml
.github/workflows/release_nightly.yml
.github/workflows/store_pytest_durations.yml
.github/workflows/style-check-py.yml
.github/workflows/typescript_test.yml
Replaced usage of local setup-uv action with external astral-sh/setup-uv@v6, adding cache parameters and dynamic Python version input where applicable.

Sequence Diagram(s)

sequenceDiagram
    participant Workflow
    participant astral-sh/setup-uv

    Workflow->>astral-sh/setup-uv: Invoke setup-uv@v6 with python-version, enable-cache, cache-dependency-glob
    astral-sh/setup-uv-->>Workflow: Sets up Python environment with uv and caching
    Workflow->>Workflow: Continue with job steps
Loading

Possibly related PRs

  • ci: fix uv cache in CI workflows #8319: Removes a cache restoration step and an environment variable related to UV cache from the composite action and workflows; both PRs address "uv" setup and caching in CI workflows.

Suggested labels

size:M, lgtm

Suggested reviewers

  • mfortman11
  • jordanrfrazier

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@coderabbitai coderabbitai Bot changed the title @coderabbitai chore(ci): replace local uv setup action with astral-sh/setup-uv@v6 Jun 11, 2025
@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Jun 11, 2025
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 9

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4ba20a8 and a9d728e.

📒 Files selected for processing (12)
  • .github/actions/setup-uv/action.yml (0 hunks)
  • .github/workflows/codeflash.yml (1 hunks)
  • .github/workflows/docker-build.yml (2 hunks)
  • .github/workflows/integration_tests.yml (1 hunks)
  • .github/workflows/lint-py.yml (1 hunks)
  • .github/workflows/nightly_build.yml (1 hunks)
  • .github/workflows/python_test.yml (3 hunks)
  • .github/workflows/release.yml (2 hunks)
  • .github/workflows/release_nightly.yml (2 hunks)
  • .github/workflows/store_pytest_durations.yml (1 hunks)
  • .github/workflows/style-check-py.yml (1 hunks)
  • .github/workflows/typescript_test.yml (1 hunks)
💤 Files with no reviewable changes (1)
  • .github/actions/setup-uv/action.yml
🧰 Additional context used
🪛 actionlint (1.7.7)
.github/workflows/nightly_build.yml

36-36: property "python-version" is not defined in object type {}

(expression)

.github/workflows/codeflash.yml

30-30: property "python-version" is not defined in object type {}

(expression)

.github/workflows/release.yml

70-70: property "python-version" is not defined in object type {}

(expression)


138-138: property "python-version" is not defined in object type {}

(expression)

.github/workflows/docker-build.yml

198-198: property "python-version" is not defined in object type {}

(expression)

.github/workflows/store_pytest_durations.yml

30-30: property "python-version" is not defined in object type {}

(expression)

.github/workflows/release_nightly.yml

80-80: property "python-version" is not defined in object type {}

(expression)


161-161: property "python-version" is not defined in object type {}

(expression)

🔇 Additional comments (8)
.github/workflows/integration_tests.yml (1)

47-50: Standardize environment setup with external setup-uv action
Replaced the local composite action with astral-sh/setup-uv@v6, enabled cache via uv.lock, and correctly passing ${{ matrix.python-version }} to align with the matrix.

.github/workflows/lint-py.yml (1)

33-36: Adopt external setup-uv action with caching
This step correctly uses astral-sh/setup-uv@v6, enables cache on uv.lock, and passes ${{ matrix.python-version }} matching the defined matrix.

.github/workflows/python_test.yml (3)

51-54: Update build job to use external setup-uv with cache
The build job properly replaces the local action with astral-sh/setup-uv@v6, enabling caching on uv.lock and passing ${{ matrix.python-version }} per the matrix.


77-80: Adopt external setup-uv in integration-tests job
The integration-tests step is updated correctly, enabling cache and using ${{ matrix.python-version }} aligned with its matrix.


100-103: Use external setup-uv in test-cli job
The test-cli job correctly switches to astral-sh/setup-uv@v6 with caching enabled and ${{ matrix.python-version }} sourced from its matrix.

.github/workflows/style-check-py.yml (1)

21-25: Use external setup-uv action with caching
Invocation of astral-sh/setup-uv@v6 with enable-cache, cache-dependency-glob, and the matrix-sourced python-version is consistent with other workflows.

.github/workflows/docker-build.yml (1)

344-348: Correctly using matrix in restart-space job
The restart-space job defines a matrix for python-version, so referencing ${{ matrix.python-version }} is valid here.

.github/workflows/typescript_test.yml (1)

295-297: Consistent external action usage

Switching from the local composite to astral-sh/setup-uv@v6 with caching enabled aligns this workflow with other standard setups.

Comment thread .github/workflows/nightly_build.yml Outdated
Comment thread .github/workflows/codeflash.yml
Comment thread .github/workflows/store_pytest_durations.yml Outdated
Comment thread .github/workflows/release.yml Outdated
Comment thread .github/workflows/release.yml Outdated
Comment thread .github/workflows/release_nightly.yml Outdated
Comment thread .github/workflows/release_nightly.yml Outdated
Comment on lines +195 to 199
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
python-version: ${{ matrix.python-version }}
- name: Install the project
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.

⚠️ Potential issue

Undefined matrix.python-version in build job
The build job references ${{ matrix.python-version }} but does not define a matrix, leading to errors.

Introduce a strategy matrix, for example:

@@ build:
     needs: [get-version, setup]
+    strategy:
+      matrix:
+        python-version: ['3.13']
     steps:
       - name: "Setup Environment"
         uses: astral-sh/setup-uv@v6
         with:
           enable-cache: true
           cache-dependency-glob: "uv.lock"
-          python-version: ${{ matrix.python-version }}
+          python-version: ${{ matrix.python-version }}
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
python-version: ${{ matrix.python-version }}
- name: Install the project
build:
needs: [get-version, setup]
strategy:
matrix:
python-version: ['3.13']
steps:
- name: "Setup Environment"
uses: astral-sh/setup-uv@v6
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
python-version: ${{ matrix.python-version }}
- name: Install the project
🧰 Tools
🪛 actionlint (1.7.7)

198-198: property "python-version" is not defined in object type {}

(expression)

🤖 Prompt for AI Agents
In .github/workflows/docker-build.yml around lines 195 to 199, the build job
uses the undefined variable matrix.python-version causing errors. To fix this,
define a strategy matrix for the build job that includes python-version values,
such as a list of Python versions to test against. This will properly initialize
matrix.python-version and resolve the reference error.

Comment thread .github/workflows/typescript_test.yml Outdated
@ogabrielluiz ogabrielluiz disabled auto-merge June 11, 2025 18:35
@ogabrielluiz ogabrielluiz added this pull request to the merge queue Jun 11, 2025
Merged via the queue into main with commit b378eb8 Jun 11, 2025
22 checks passed
@ogabrielluiz ogabrielluiz deleted the fix-uv-caching-again branch June 11, 2025 19:06
ogabrielluiz added a commit to bkatya2001/langflow that referenced this pull request Jun 24, 2025
…angflow-ai#8491)

* chore: remove setup-uv action configuration file as it is no longer needed

* chore: update setup-uv action to use the official action across all workflows

* chore: disable cache pruning in all workflows to improve build stability

* chore: update Python version to 3.13 and add pre-release description in workflows
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ignore-for-release lgtm This PR has been approved by a maintainer size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants