gleam: File IO Errors on NTFS, secondary devices

Related to https://github.com/gleam-lang/gleam/issues/2680 Gleam Version: v1.0.0 Operating System: Windows 10

Problem: If i try to run gleam run, gleam build, gleam test or gleam check i get Following error:

error: File IO failure
An error occurred while trying to delete this directory:
    Z:\...\build\dev\erlang
The error message from the file IO library was:
    Die Datei kann nicht geöffnet werden, weil sie gerade gelöscht wird. (os error 303)

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 24 (7 by maintainers)

Most upvoted comments

@sepiatonal the fix is not yet included in the latest release

I managed to reproduce this issue in an alpine docker image with bindfs

FROM docker.io/library/alpine:edge

RUN echo "http://dl-cdn.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories
RUN apk update && apk upgrade && apk add strace bindfs gleam

COPY <<EOF /opt/gleam_bug_reprod.sh
#!/bin/sh
set -ex
bindfs --write-rate=100000 --read-rate=100000 bug_gleam gleam_bug_bind
cd gleam_bug_bind
strace gleam test -t erlang
EOF

RUN chmod +x /opt/gleam_bug_reprod.sh && \
    gleam new /opt/bug_gleam && \
    mkdir /opt/gleam_bug_bind 

WORKDIR /opt
ENTRYPOINT [ "/opt/gleam_bug_reprod.sh" ]

Running it must be done with

docker build -t gleam_bug -f Dockerfile .
docker run --rm -it --device /dev/fuse --privileged gleam_bug

Could be worth a try!

I can’t test it because it is a company managed PC but im pretty sure it is a problem with antivirus because on my computer at home it worked without problems.

I will look in to it (or try to look in to it)