Sitelet https://github.com/fsprojects/Paket/issues/1152
Skip to content

File-Access error while calling paket install #1152

Description

@BADF00D

From time to time and recently more often I got an error that looks like the following:

$ paket install
Paket version 2.15.1.0
Skipping resolver for group LegacyApps since it is already up-to-date
Skipping resolver for group Main since it is already up-to-date
c:\somepath\paket.lock is already up-to-date
Downloading FAKE 4.3.4
Something went wrong while downloading FAKE 4.3.4 - Trying again.
Downloading FAKE 4.3.4
Paket failed with:
        Could not download FAKE 4.3.4 from http://path-to-klondike:8080/api/packages/FAKE/4.3.4/content.
    Der Prozess kann nicht auf die Datei "C:\Users\account\AppData\Local\NuGet\Cache\FAKE.4.3.4.nupkg" zugreifen, da sie von ein

When I repeat the call the error is gone, at least sometimes. Sometime the error is gone if I simply delete all files that start with the paket FAKE.4.3.4* and repeat the call.

The error occurs with different nuget packages, FAKE is only the example that causes the problem at the moment.

This error even stays if I restart Windows and do nothing but calling paket install in git bash.

By the way, the nuget package seems to be successfully downloaded.

Content of the *failed file:
System.IO.IOException: Der Prozess kann nicht auf die Datei "C:\Users\account\AppData\Local\NuGet\Cache\FAKE.4.3.4.s547206449.json" zugreifen, da sie von einem anderen Prozess verwendet wird. bei System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) bei System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) bei System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) bei System.IO.StreamWriter.CreateFile(String path, Boolean append, Boolean checkHost) bei System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize, Boolean checkHost) bei System.IO.File.InternalWriteAllText(String path, String contents, Encoding encoding, Boolean checkHost) bei Paket.NuGetV2.getDetailsFromNuGet@293-6.Invoke(Tuple2 _arg1)
bei Microsoft.FSharp.Control.AsyncBuilderImpl.args@835-1.Invoke(a a)`

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions