deno icon indicating copy to clipboard operation
deno copied to clipboard

watchFs throws Function not implemented (os error 38) wenn running in Docker with on Apple M1 host

Open ivpdev opened this issue 3 years ago • 2 comments

When running Deno.watchFs on Deno inside of a Docker container not implemented error is thrown. When running Deno.watchFs in Deno installed directly to host system everything works as expected.

Reproduce steps

  1. Run Deno container with 'docker run -it --init denoland/deno:1.22.0 repl'
  2. Execute following comand inside of Deno REPL 'Deno.watchFs('.')'

Result Uncaught Error: Function not implemented (os error 38) at Object.opSync (deno:core/01_core.js:172:12) at new FsWatcher (deno:runtime/js/40_fs_events.js:18:24) at Object.watchFs (deno:runtime/js/40_fs_events.js:63:12) at :2:6

Expected Result no error thrown

Environment

  • Docker Desktop 4.8.2
  • Docker version 20.10.14, build a224086
  • MacBook Pro (14-inch, 2021)
  • MacOS Monterey 12.0.1

ivpdev avatar May 20 '22 09:05 ivpdev

@ivpdev Here's the root issue in Docker: https://github.com/docker/for-mac/issues/6174, specifically:

However, attempts to run Intel-based containers on Apple silicon machines under emulation can crash as qemu sometimes fails to run the container. In addition, filesystem change notification APIs (inotify) do not work under qemu emulation. Even when the containers do run correctly under emulation, they will be slower and use more memory than the native equivalent.

AaronO avatar May 20 '22 15:05 AaronO

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jul 21 '22 05:07 stale[bot]

This issue is not resolved, problem still exists with deno:alpine-1.34.1 image. @kitsonk please reopen

kirill-dev-pro avatar Jun 03 '23 18:06 kirill-dev-pro