fsprojects / Paket

A dependency manager for .NET with support for NuGet packages and Git repositories.
https://fsprojects.github.io/Paket/
MIT License
1.99k stars 520 forks source link

Paket restore IOException: read-only filesystem #4251

Open sheridanchris opened 3 months ago

sheridanchris commented 3 months ago

Description

The dotnet paket restore command fails when encountering a read-only file-system.

I use Nix and Direnv for managing my projects and a .direnv directory is created with symlinks to my read-only root filesystem.

Repro steps

Unable to reproduce at this moment in a non-nix environment. I will update the issue when I have.

Expected behavior

Paket restores as normal.

Actual behavior

> dotnet paket restore

Paket version 8.0.3+75b30cdcb8859e8d129f139444d9b9b600bfff07
Total time taken: 0 milliseconds
Paket failed with
-> IOException: Read-only file system : '/home/christian/Programming/Marten.FSharp/.direnv/flake-inputs/yknlydpjczha2l9f4yd3wz5nhj4g4rwq-source/pkgs/test/dotnet/project-references/application/obj'

Known workarounds

No workarounds have been found at this time.

joprice commented 2 months ago

I'm seeing this when using direnv with a flake, but only when I add a paket.local file to override a dependency.

joprice commented 1 month ago

This also happens when I try to use the git override within the paket.dependencies file, so I'm unable to test packages locally. This hinders contributing to packages as a common pattern is to test them locally against a known working project. Is there any other way to depend on a package locally to work around this?