[GH-ISSUE #328] docker cp fails with actions-rs-toolchain #229

Closed
opened 2026-03-01 21:41:32 +03:00 by kerem · 5 comments
Owner

Originally created by @tyler274 on GitHub (Aug 2, 2020).
Original GitHub issue: https://github.com/nektos/act/issues/328

Running act locally on windows 10 fails with MODULE_NOT_FOUND here, setting the path key in the yml didn't seem to affect it.
Running ACT within a WSL2 shell works though.

PS C:\Users\tyler\Code\ggpo-rs> act -j check
[CI/Check ubuntu-latest (nightly)-2] 🧪  Matrix: map[os:ubuntu-latest toolchain:nightly]
[CI/Check ubuntu-latest (stable)-1 ] 🧪  Matrix: map[os:ubuntu-latest toolchain:stable]
[CI/Check ubuntu-latest (nightly)-2] 🚀  Start image=node:12.6-buster-slim
[CI/Check ubuntu-latest (stable)-1 ] 🚀  Start image=node:12.6-buster-slim
[CI/Check ubuntu-latest (stable)-1 ]   🐳  docker run image=node:12.6-buster-slim entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[]
[CI/Check ubuntu-latest (stable)-1 ]   🐳  docker cp src=C:\Users\tyler\Code\ggpo-rs/. dst=\github\workspace
[CI/Check ubuntu-latest (stable)-1 ] ⭐  Run actions/checkout@v2
[CI/Check ubuntu-latest (stable)-1 ]   ✅  Success - actions/checkout@v2
[CI/Check ubuntu-latest (stable)-1 ] ⭐  Run toolchain
[CI/Check ubuntu-latest (stable)-1 ]   ☁  git clone 'https://github.com/actions-rs/toolchain' # ref=v1
[CI/Check ubuntu-latest (stable)-1 ]   🐳  docker cp src=act/actions-rs-toolchain@v1 dst=/actions\
| internal/modules/cjs/loader.js:628
|     throw err;
|     ^
|
| Error: Cannot find module '/github/workspace/\actions\actions-rs-toolchain@v1\dist\index.js'
|     at Function.Module._resolveFilename (internal/modules/cjs/loader.js:625:15)
|     at Function.Module._load (internal/modules/cjs/loader.js:527:27)
|     at Function.Module.runMain (internal/modules/cjs/loader.js:839:10)
|     at internal/main/run_main_module.js:17:11 {
|   code: 'MODULE_NOT_FOUND',
|   requireStack: []
| }

action.yml that triggers it.

on: [push, pull_request]

name: CI

jobs:
  check:
    name: Check ${{ matrix.os }} (${{ matrix.toolchain }})
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest]
        toolchain: [stable, nightly]
    steps:
      - uses: actions/checkout@v2
      - name: toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: ${{ matrix.toolchain }}
          override: true
      - uses: actions/cache@v2
        with:
          path: |
            ~/.cargo/registry
            ~/.cargo/git
            target
          key: ${{ runner.os }}-${{ matrix.toolchain }}-cargo-${{ hashFiles('**/Cargo.lock') }}
      - uses: actions-rs/cargo@v1
        with:
          command: check
Originally created by @tyler274 on GitHub (Aug 2, 2020). Original GitHub issue: https://github.com/nektos/act/issues/328 Running act locally on windows 10 fails with MODULE_NOT_FOUND here, setting the path key in the yml didn't seem to affect it. Running ACT within a WSL2 shell works though. ``` PS C:\Users\tyler\Code\ggpo-rs> act -j check [CI/Check ubuntu-latest (nightly)-2] 🧪 Matrix: map[os:ubuntu-latest toolchain:nightly] [CI/Check ubuntu-latest (stable)-1 ] 🧪 Matrix: map[os:ubuntu-latest toolchain:stable] [CI/Check ubuntu-latest (nightly)-2] 🚀 Start image=node:12.6-buster-slim [CI/Check ubuntu-latest (stable)-1 ] 🚀 Start image=node:12.6-buster-slim [CI/Check ubuntu-latest (stable)-1 ] 🐳 docker run image=node:12.6-buster-slim entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[] [CI/Check ubuntu-latest (stable)-1 ] 🐳 docker cp src=C:\Users\tyler\Code\ggpo-rs/. dst=\github\workspace [CI/Check ubuntu-latest (stable)-1 ] ⭐ Run actions/checkout@v2 [CI/Check ubuntu-latest (stable)-1 ] ✅ Success - actions/checkout@v2 [CI/Check ubuntu-latest (stable)-1 ] ⭐ Run toolchain [CI/Check ubuntu-latest (stable)-1 ] ☁ git clone 'https://github.com/actions-rs/toolchain' # ref=v1 [CI/Check ubuntu-latest (stable)-1 ] 🐳 docker cp src=act/actions-rs-toolchain@v1 dst=/actions\ | internal/modules/cjs/loader.js:628 | throw err; | ^ | | Error: Cannot find module '/github/workspace/\actions\actions-rs-toolchain@v1\dist\index.js' | at Function.Module._resolveFilename (internal/modules/cjs/loader.js:625:15) | at Function.Module._load (internal/modules/cjs/loader.js:527:27) | at Function.Module.runMain (internal/modules/cjs/loader.js:839:10) | at internal/main/run_main_module.js:17:11 { | code: 'MODULE_NOT_FOUND', | requireStack: [] | } ``` action.yml that triggers it. ``` on: [push, pull_request] name: CI jobs: check: name: Check ${{ matrix.os }} (${{ matrix.toolchain }}) runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest] toolchain: [stable, nightly] steps: - uses: actions/checkout@v2 - name: toolchain uses: actions-rs/toolchain@v1 with: profile: minimal toolchain: ${{ matrix.toolchain }} override: true - uses: actions/cache@v2 with: path: | ~/.cargo/registry ~/.cargo/git target key: ${{ runner.os }}-${{ matrix.toolchain }}-cargo-${{ hashFiles('**/Cargo.lock') }} - uses: actions-rs/cargo@v1 with: command: check ```
kerem 2026-03-01 21:41:32 +03:00
  • closed this issue
  • added the
    stale
    label
Author
Owner

@github-actions[bot] commented on GitHub (Oct 3, 2020):

Issue is stale and will be closed in 7 days unless there is new activity

<!-- gh-comment-id:703012072 --> @github-actions[bot] commented on GitHub (Oct 3, 2020): Issue is stale and will be closed in 7 days unless there is new activity
Author
Owner

@tyler274 commented on GitHub (Oct 3, 2020):

Bad bot

<!-- gh-comment-id:703015649 --> @tyler274 commented on GitHub (Oct 3, 2020): Bad bot
Author
Owner

@siedentop commented on GitHub (Oct 29, 2020):

Anyone know of a work-around?

<!-- gh-comment-id:718360468 --> @siedentop commented on GitHub (Oct 29, 2020): Anyone know of a work-around?
Author
Owner

@justinmoon commented on GitHub (Nov 18, 2020):

I'm getting same thing on Windows 10.

The /github/workspace/\actions\actions-rs-toolchain@v1\dist\index.js url seems suspect -- combines / Linux paths and \ Windows paths.

That location is inside Docker, right? If so, then it wont understand the \'s.

<!-- gh-comment-id:730021566 --> @justinmoon commented on GitHub (Nov 18, 2020): I'm getting same thing on Windows 10. The `/github/workspace/\actions\actions-rs-toolchain@v1\dist\index.js` url seems suspect -- combines `/` Linux paths and `\` Windows paths. That location is inside Docker, right? If so, then it wont understand the `\`'s.
Author
Owner

@github-actions[bot] commented on GitHub (Jan 16, 2021):

Issue is stale and will be closed in 14 days unless there is new activity

<!-- gh-comment-id:761279605 --> @github-actions[bot] commented on GitHub (Jan 16, 2021): Issue is stale and will be closed in 14 days unless there is new activity
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#229
No description provided.