Skip to content

Version 1.39.0 causing CircleCI deployment script to fail. #5928

Closed

Description

@gevorggalstyan

This is a Bug Report

Description

  • What went wrong? After updating to v1.39.0 our deployment script crashes on CircleCI.
  • What did you expect should have happened? The update should not affect the deploy process and deploy as 1.38.0 was doing.
  • What was the config you used? In terms of this issue, I think it is worth mentioning that we are using serverless-webpack plugin.
  • What stacktrace or error message from your provider did you see? I have pasted the deployment logs at the bottom.

Additional Data

Serverless: Uploading CloudFormation file to S3...
Serverless: Uploading artifacts...

Error --------------------------------------------------

ENOENT: no such file or directory, stat '/home/circleci/repo/.serverless/.serverless/serverless-api.zip'

 For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.

Get Support --------------------------------------------
Docs: docs.serverless.com
Bugs: github.com/serverless/serverless/issues
Issues: forum.serverless.com

Your Environment Information -----------------------------
OS: linux
Node Version: 8.15.1
Serverless Version: 1.39.0

Exited with code 1

Activity

  1. PMCorbett commented on Mar 15, 2019

    @PMCorbett

    I am seeing precisely the same issue on CircleCI. I am also using the serverless-webpack plugin

    Serverless: Uploading CloudFormation file to S3...
    Serverless: Uploading artifacts...

    Error --------------------------------------------------

    ENOENT: no such file or directory, stat '/home/circleci/repo/.serverless/.serverless/engage.zip'

     For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.
    

    Get Support --------------------------------------------
    Docs: docs.serverless.com
    Bugs: github.com/serverless/serverless/issues
    Issues: forum.serverless.com

    Your Environment Information -----------------------------
    OS: linux
    Node Version: 8.11.4
    Serverless Version: 1.39.0

    Exited with code 1

  2. twitchy9000 commented on Mar 15, 2019

    @twitchy9000

    I am seeing the same issue when attempting to deploy from CircleCI and from local.

    serverless-webpack
    package:
    individually: true

    Serverless: Packaging service...

    Serverless Error ---------------------------------------

    No getBrand.zip file found in the package path you provided.

    Get Support --------------------------------------------
    Docs: docs.serverless.com
    Bugs: github.com/serverless/serverless/issues
    Issues: forum.serverless.com

    Your Environment Information -----------------------------
    OS: darwin
    Node Version: 8.10.0
    Serverless Version: 1.39.0

  3. srdone commented on Mar 15, 2019

    @srdone

    I am also seeing the issue locally and on our build server. It appears to be drilling down into the /.serverless folder twice to look for the .zip file, given the ENOENT message.

    I have confirmed that 1.38.0 is working without issue.

    I am also using the serverless-webpack plugin.

  4. mbunge commented on Mar 15, 2019

    @mbunge

    Confirmed for local Deployment and AWS CodeDeploy / Pipelines too!

    We are also using serverless-webpack.

    Local

      ENOENT: no such file or directory, stat '/Users/tackleberry/projects/my-custom-project-name/.serverless/.serverless/my-custom-project-name.zip'
    
         For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.
    

    /.serverless/.serverless seems to be wrong at this point.

    CodeBuild Error:

    Serverless Warning --------------------------------------
     A valid file to satisfy the declaration 'file(resources/dynamodb-table.yml)' could not be found.
     Serverless: Uploading CloudFormation file to S3...
    Serverless: Uploading artifacts...
     Error --------------------------------------------------
    
    ENOENT: no such file or directory, stat 'artifacts/dev/.serverless/my-fixed-project-name.zip'
    
  5. dinamic commented on Mar 15, 2019

    @dinamic

    Confirmed. It also happens on our setup.

    I tried to fix it myself by editing .serverless/serverless-state.json to no avail.

    Granted, I have no clue how serverless works, but was trying to make it work somehow. I can't deploy no more. :(

  6. mbunge commented on Mar 15, 2019

    @mbunge

    Forcing [email protected] in CircleCI config and for AWS in your CodeBuildDeployProject.Source.BuildSpec config.

  7. dinamic commented on Mar 15, 2019

    @dinamic

    Going thru changes, I feel like this is the one that broke things.

    #5297

  8. guice commented on Mar 15, 2019

    @guice

    Same issue. It's global. Happens with every service of ours.

  9. dschep commented on Mar 15, 2019

    @dschep
    Contributor

    Are all of you using serverless-webpack like @mbunge is?

  10. rrosenblum commented on Mar 15, 2019

    @rrosenblum

    I am having this issue, and I am not using serverless-webpack.

    The error that I am seeing is
    No <package>.zip file found in the package path you provided.

  11. guice commented on Mar 15, 2019

    @guice

    I am using serverless-webpack. The error I get is a double .serverless/.serverless in the package path.

  12. dschep commented on Mar 15, 2019

    @dschep
    Contributor

    @rrosenblum, could you provide your serverless.yml?

  13. rrosenblum commented on Mar 15, 2019

    @rrosenblum

    Here is a copy of my serverless.yml.

  14. hiloboy0119 commented on Mar 15, 2019

    @hiloboy0119

    I am getting the error as well. I'm not using serverless-webpack. I am however using serverless-python-requirements and I saw a related issue on their github:

    serverless/serverless-python-requirements#332

  15. keithalpichi commented on Mar 15, 2019

    @keithalpichi

    I'm also encountering Jenkins build issues using the latest version 1.39.0:

      Serverless Error ---------------------------------------
     
      No src-some-package-name-dev-run.zip file found in the package path you provided.
     
      Your Environment Information -----------------------------
         OS:                     linux
         Node Version:           8.10.0
         Serverless Version:     1.39.0
    

    And our serverless.yml:

    
    service: some-package-name
    
    plugins:
      - serverless-python-requirements
      - serverless-pseudo-parameters
      - serverless-domain-manager
    
    provider:
      name: aws
      runtime: python3.6
      versionFunctions: true
        
    package:
      individually: true
      exclude:
        - 'example/**'
        - 'numpy/*.pyc'
        - 'numpy/**/*.pyc'
        - 'code/**'
        - './**/*.pyc'
        - './**/__pycache__/*.pyc'
        - 'requirements/**/*.pyc'
        - './serverless/requirements/**/*.pyc'
        - 'node_modules/**/*.md'
        - '*.ts'
        - 'src/*.ts'
        - 'src/**/*.ts'
        - 'src/*.json'
        - 'src/**/*.json'
        - README.md
        - '*.json'
        - 'setup/*'
        - 'setup'
        - 'test/'
        - .gitignore
        - serverless.yml
        - 'test_set'
        - 'test_set/**'
        - 'json_contract'
        - 'json_contract/**'
        - 'codes/__pycache__'
        - 'codes/__pycache__/**'
        - 'train'
        - 'db'
        - 'para/**'
        - 'old/**'
    
    functions:
      run:
        handler: index.run
        module: src
        timeout: 300
        memorySize: 3008
    
    custom:
      pythonRequirements:
        dockerizePip: true
        slim: true
        slimPatterns:
          - "**/*.egg-info*"
          - "**/*.pyc"
          - "**/tests"
          - "test/*"
    

    I realize the error occurs before deploying to AWS S3.

  16. Kennytian commented on Mar 16, 2019

    @Kennytian

    My workaround is downgrade to 1.38.0, yarn global add [email protected]

  17. efimk-lu commented on Mar 16, 2019

    @efimk-lu

    @Kennytian looks like that's the only solution right now. My general strategy was to always install the latest serverless version on CircleCI, but lately serverless became unstable and starting to think about version pinning.

  18. softprops commented on Mar 16, 2019

    @softprops
    Contributor

    Having the same issue. I maintain the serverless rust plugin. same symptom, looks to be same cause. I set the package.artifact path to my build artifacts. The package gets interpreted incorrectly now. at least inconsistently as it has in the past.

    softprops/serverless-rust#30 (comment)

  19. softprops commented on Mar 16, 2019

    @softprops
    Contributor

    Would it be possible to revert #5297 and publish a patch version? It seems its causing numerous regressions across the ecosystem.

    Reviewing the summary

    Because artifacts are generated in the .serverless directory first, even if a package path was provided, the reference to the artefact zip file was incorrectly pointing at the .serverless directory. This only needs to be changed at the time the service state is saved, so I have added a few lines to the saveServiceState.js file of the AWS package plugin to fix the paths in the service configuration before saving.

    Not all artifacts are generated in the .serverless directory. I think the correct behavior should be if a path is provided, serverless should honor it as is, not change it.

  20. pmuens commented on Mar 18, 2019

    @pmuens
    Contributor

    Just reverted #4188 which seems to be the root cause. Patch release should be out in ~30 minutes...

  21. mbunge commented on Mar 20, 2019

    @mbunge

    Just reverted #4188 which seems to be the root cause. Patch release should be out in ~30 minutes...

    Nice. Thanks!

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions