Skip to content

With two lychee-action steps in a row you get -> tar: lychee: Cannot open: File exists #188

@CAMOBAP

Description

@CAMOBAP

Intro

I have a huge list of files to analyze and I decided to split URL and email validation to different steps

...
    - name: Run lychee for emails
      uses: lycheeverse/lychee-action@v1.6.1
      with:
        args: --no-progress --exclude "(https?)|(file)://" --cache --max-cache-age 1d '_site/**/*.html'
        fail: true

    - name: Run lychee for links
       with:
        args: --no-progress --exclude-mail --cache --max-cache-age 1d '_site/**/*.html'
        fail: true
...

Problem

In the second step, I get:

...
lychee
tar: lychee: Cannot open: File exists
tar: Exiting with failure status due to previous errors
Error: Process completed with exit code 2.
...

Probably it happens because tar has already been downloaded.
Probably the right solution is to reuse existing tag/extracted files it they exists

Workaround

...
    - name: Run lychee for emails
      uses: lycheeverse/lychee-action@v1.6.1
      with:
        args: --no-progress --exclude "(https?)|(file)://" --cache --max-cache-age 1d '_site/**/*.html'
        fail: false

    - name: Run lychee for links
      run: lychee --no-progress --exclude-mail --cache --max-cache-age 1d '_site/**/*.html'
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions