Workspaces not working properly after successful download

Hi,

I am trying to use workspaces to cache yarn install results.

I have the following in my travis.yaml

jobs:
  include:
    - stage: Install
      script:
        - yarn install
      workspaces:
        create:
          name: ws1
          paths:
          - node_modules
    - stage: Linters
      name: yarn lint:all
      workspaces:
        use: ws1
      script:
        - yarn lint:all

It seems that workspace is generated and uploaded properly.

The command "yarn install" exited with 0.
workspaces_create
Creating workspaces
Workspace: ws1
0.00s1.49s adding <path>/node_modules to workspace
0.00s1.83schanges detected, packing new archive
gzip: warning: GZIP environment variable is deprecated; use an alias or script
uploading 261234742/ws1.tgz
workspace uploaded

And it seems to fetch it successfully and there are no errors, but then a command is failed because there are no node_modules :confused:

Fetching workspace ws1
0.00s1.37sattempting to download workspace archive
fetching 261234742/ws1.tgz
found workspace
0.10s$ tar -xPzf ${CASHER_DIR}/ws1-fetch.tgz
$ node --version
v18.14.2
$ npm --version
9.5.0
$ nvm --version
0.39.3
0.29s$ yarn lint:all
yarn run v1.22.19
$ lint: command not found
error Command failed with exit code 127.

I am not sure what’s the problem here(
Also, why does it tries to unzip the ${CASHER_DIR}/ws1-fetch.tgz when the uploaded filename (AFAIU) is 261234742/ws1.tgz?

thank you