Inedo Community Forums Forums
    • Recent
    • Tags
    • Popular
    • Login

    Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

    If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

    BuildMaster Create-Artifact - Handle does not support synchronous operations.

    Scheduled Pinned Locked Moved Support
    5 Posts 3 Posters 12 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • V Offline
      vishal_2561
      last edited by

      Hello,

      I am getting below error in "Create-Artifact".

      Debug: Found 1800 matches (193724990 bytes total).
      Error: Unhandled exception: System.ArgumentException: Handle does not support synchronous operations. The parameters to the FileStream constructor may need to be changed to indicate that the handle was opened asynchronously (that is, it was opened explicitly for overlapped I/O).

      Script has two create-artifact, one for "Test" and another for "Production".

      From path: D:\BuildMaster\Temp{Website_Test/Website_Production}

      It works fine for "Test" but fails in "Production". But if I change path to D:\BuildMaster\Temp_E$ExecutionId* then it fails for both "Test" and "Production".

      stevedennisS 1 Reply Last reply Reply Quote 0
      • stevedennisS Offline
        stevedennis inedo-engineer @vishal_2561
        last edited by

        Hi @vishal_2561 ,

        Can you provide us with a full log/stack trace? That's an unusual error and we'd like to get some more context on where it's coming from.

        Thanks,
        Steve

        1 Reply Last reply Reply Quote 0
        • V Offline
          vishal_2561
          last edited by rhessinger

          Hi @stevedennis ,

          Below is the log.

          Debug: Using TcpAgent agent on QA
           Info: Getting list of files in D:\BuildMaster\Website\Content\C_C\ProgramData\InedoAgent\BuildMaster\Temp\_E2605\Website\obj\Production\Package\PackageTmp to add to artifact...
          Debug: Found 1800 matches (193724993 bytes total).
          Error: Unhandled exception: System.ArgumentException: Handle does not support synchronous operations. The parameters to the FileStream constructor may need to be changed to indicate that the handle was opened asynchronously (that is, it was opened explicitly for overlapped I/O).
             at System.IO.FileStream.VerifyHandleIsSync()
             at System.IO.FileStream..ctor(SafeFileHandle handle, FileAccess access, Int32 bufferSize, Boolean isAsync)
             at System.IO.FileStream..ctor(SafeFileHandle handle, FileAccess access)
             at Inedo.IO.FileEx.Open(String fileName, FileMode fileMode, FileAccess fileAccess, FileShare fileShare, FileOptions fileOptions)
             at Inedo.Agents.RemoteFileHost.<OpenFileAsync>d__1.MoveNext()
          --- End of stack trace from previous location where exception was thrown ---
             at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
             at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
             at Inedo.Agents.AgentCommand`1.<Inedo-Agents-IAgentCommandWithResponse-ExecuteAsync>d__5.MoveNext()
          --- End of stack trace from previous location where exception was thrown ---
             at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
             at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
             at Inedo.Agents.AgentCommandDispatcher.<ExecuteCommandAsync>d__7.MoveNext()
          

          We are using Buildmaster of version 6.2.20.

          1 Reply Last reply Reply Quote 0
          • rhessingerR Offline
            rhessinger inedo-engineer
            last edited by

            Hi @vishal_2561,

            This sounds like it could potentially be an issue with the file becoming locked at the operating system level (like an anti-virus scan, a snapshot taken, etc...). But to be sure, could you please enable "Verbose logging" on your Deploy-Artifact operation and send us the execution again? That will give us a little more detail about the issue. If that execution is too sensitive, you could email it to us at support@inedo.com and use the subject [QA-1175] - Execution log and let us know you sent it.

            Thanks,
            Rich

            Products Engineer, Inedo

            1 Reply Last reply Reply Quote 0
            • V Offline
              vishal_2561
              last edited by

              Hi @rhessinger ,

              Verbose doesn't have much details, all "Capturing files..." messages. I changed buildmasteragent root directory and its working now, so as you said it might be something at OS level.

              Thanks.

              1 Reply Last reply Reply Quote 0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              • 1 / 1
              • First post
                Last post
              Inedo Website Home • Support Home • Code of Conduct • Forums Guide • Documentation