Skip to content

detectEmptyWorkdir() doesn't consider the working-directory input #642

Description

@Alexander01998

Using a setup like this:

  - name: Set up uv
    uses: astral-sh/setup-uv@v7
    with:
      enable-cache: true
      working-directory: /some/non-empty/directory

where /some/non-empty/directory is a non-empty directory and . is an empty directory, the action produces the warning:

Warning: Empty workdir detected. This may cause unexpected behavior. You can enable ignore-empty-workdir to mute this warning.

even though /some/non-empty/directory is not empty.

It's caused by this line in setup-uv.ts, which checks "." instead of using the workingDirectory input.

I could be wrong, but this doesn't seem to be the intended behavior, since the workdir that matters for uv is never actually checked for emptiness.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions