mikehardy/buildcache-action

buildcache: failure during restore - /buildcache/bin/clang: File exists

Closed this issue · 1 comments

My first run after setting this up completed successfully and wrote to the cache, but then when trying again I'm getting this error trying to restore from the cache:

Run mikehardy/buildcache-action@v2
buildcache: release file based on runner os is buildcache-macos.zip
buildcache: installing from https://github.com/mbitsnbites/buildcache/releases/download/v0.28.2/buildcache-macos.zip
##[debug]Downloading https://github.com/mbitsnbites/buildcache/releases/download/v0.28.2/buildcache-macos.zip
##[debug]Destination /Users/runner/work/_temp/1dfa4221-bd80-4a48-b622-9[37](https://github.com/***/***-app-v4/actions/runs/4567835920/jobs/8062288634#step:4:38)474b53ace
##[debug]download complete
buildcache: download path /Users/runner/work/_temp/1dfa4221-bd80-4a48-b622-937474b53ace
/usr/bin/unzip -o /Users/runner/work/_temp/1dfa4221-bd80-4a48-b622-937474b53ace
Archive:  /Users/runner/work/_temp/1dfa[42](https://github.com/***/***-app-v4/actions/runs/4567835920/jobs/8062288634#step:4:43)21-bd80-4a48-b622-937474b53ace
  inflating: buildcache/bin/buildcache  
  inflating: buildcache/share/lua-examples/echo_wrapper.lua  
  inflating: buildcache/share/lua-examples/ti_c6x_wrapper.lua  
  inflating: buildcache/share/lua-examples/gcc_wrapper.lua  
  inflating: buildcache/share/lua-examples/clang_tidy_wrapper.lua  
buildcache: unpacked folder /Users/runner/work/***-app-v4/***-app-v4
/bin/ln -s /Users/runner/work/***-app-v4/***-app-v4/buildcache/bin/buildcache /Users/runner/work/***-app-v4/***-app-v4/buildcache/bin/clang
ln: /Users/runner/work/***-app-v4/***-app-v4/buildcache/bin/clang: File exists
Error: buildcache: failure during restore: Error: The process '/bin/ln' failed with exit code 1
Error: Error: The process '/bin/ln' failed with exit code 1
##[debug]Node Action run completed with exit code 1
##[debug]Finishing: Run mikehardy/buildcache-action@v2

Here's the first 3 steps of my GitHub action:

    steps:
      - uses: maxim-lobanov/setup-xcode@v1
        with:
          xcode-version: 'latest-stable'

      - uses: actions/checkout@v3

      - uses: mikehardy/buildcache-action@v2

Oops, nevermind - this was my fault. buildcache/ and .buildcache/ were getting checked into my repo by my CI workflow, had to remove them and add to .gitignore. Hope this helps someone else!