"Error pushing artifact: The operation has timed out" when calling appveyor PushArtifact

I'm trying to manually deploy artifacts to AppVeyor using the following command:

appveyor PushArtifact .\fakepackage.Rcheck\tests\test-all.Rout

I keep getting the error message

"Error pushing artifact: The operation has timed out"

and no artifacts appear for the build. What am I doing wrong? Thanks! (The project is open-source, all configuration is in the .yml.)

  1. What is the size of that file? Does it exist? is it sporadic error?

    I've tested pushing an existing small file using the same command (https://ci.appveyor.com/project/appvyr/appveyor-bot-0904-0540/build...) as well as pushing a newly created empty file (https://ci.appveyor.com/project/appvyr/appveyor-bot-0904-0540/build...).

  2. The file exists, it's in the kilobytes, the error persists.

    Thanks for testing, but I haven't found this project on GitHub and hence cannot see what's different. I'll try to replicate this in an empty .yml project.

  3. I think I can replicate the problem: https://ci.appveyor.com/project/krlmlr/appveyor-artifact-test/build... . The project is on GitHub, I'm using the following .yml (not strictly minimal, but small enough I hope):

    init:
      ps: |
            Get-Date
            $ErrorActionPreference = "Stop"
    
    install:
      - ps: New-Item .\new_empty_file.txt -type file
    
    build_script:
      - ps: Write-Host "build_script" -ForegroundColor Magenta
    
    test_script:
      - ps: Write-Host "test_script" -ForegroundColor Magenta
    
    deploy_script:
      - appveyor PushArtifact .\new_empty_file.txt
    
  4. So the problem is in pushing a 0 file?

  5. No, it also happens with a non-empty file: https://ci.appveyor.com/project/krlmlr/appveyor-artifact-test/build... . Two timestamps are printed before and after the push attempt, the timeout is around two minutes.

  6. Sure, will look into that. Thanks for the test project.

  7. I've tried everything. I still don't know why, but there is something wrong with Get-Date in init section.

    Remove Get-Date and everything works: https://ci.appveyor.com/project/appvyr/appveyor-artifact-test/build...

    Put it back and it timeouts all calls to Agent API: https://ci.appveyor.com/project/appvyr/appveyor-artifact-test/build...

  8. Hi

    I'm now having a similar problem in one of my projects. See log here.

    Here's my appveyor.yml is simple as 123

    before_build:  
      - restore_packages.bat
    
    configuration: Release
    
    on_success:
      - nuget pack JsonLd.Entities.nuspec -Version %APPVEYOR_BUILD_VERSION%
      - appveyor PushArtifact JsonLd.Entities.%APPVEYOR_BUILD_VERSION%.nupkg
    

    Regards,
    Tom

  9. Will take a look.

    -Feodor

  10. It's been fixed. Give it another try and let me know how it goes.

  11. Now I simply got Error pushing artifact: The operation has timed out

  12. OK, try using PS to upload artifact:

    on_success:
      - nuget pack JsonLd.Entities.nuspec -Version %APPVEYOR_BUILD_VERSION%
      - ps: Push-AppveyorArtifact "JsonLd.Entities.$($env:APPVEYOR_BUILD_VERSION).nupkg"
    
  13. PowerShell worked.

  14. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 01:50 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac

Recent Discussions