Workflow file not updating anymore

I have been tring to update my workflow file, but it is still stuck on a previous commit.

1 Like

After around 10 hours I have tried to push again and this time got unstuck, but now it keeps failing the validation with this error 

every step must define a uses or run key

But I do not recall any of my steps not having a uses or run key

on:
  pull_request:
    branches:
      - master

name: Deploy Nextjs dev

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
        with:
          ref: create-deployment

      - name: set up nodejs
        uses: actions/setup-node@v1
        with:
          node-version: '10.x'

      - name: install nextjs dependencies
        working-directory: ./
        run: npm install && npm run build
        env:
          ENVIRONMENT: dev

      - name: install lambda layer dependencies
        working-directory: ./deployment/libs/nodejs
        run: npm install

      - name: copy serverless bundles from nextjs
        working-directory: ./
        run: cp -r build/serverless deployment/src/


      - uses: chrislennon/action-aws-cli@v1.1
      - name: package and deploy cloudformation template
        working-directory: ./deployment/
        run: |
          aws cloudformation package \
              --template-file template.yaml \
              --output-template-file output.yaml \
              --s3-bucket ${BUCKET} \
          aws cloudformation deploy \
              --template-file output.yaml \
              --stack-name ${PROJECT} \
              --capabilities CAPABILITY_IAM \
              --parameter-overrides \
                  Environment=${ENV};
        env:
          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
          ENV: dev
          BUCKET: myBucket
          PROJECT: myStack

      - name: Copy files to S3
        working-directory: ./
        run: |
          aws s3 cp build/static/ s3://${STATIC_FILES_BUCKET_NAME}/_next/static \
              --recursive \
              --cache-control max-age=365000000,immutable
          aws s3 cp ./public/ s3://${STATIC_FILES_BUCKET_NAME}/static \
              --recursive \
              --cache-control max-age=365000000,immutable
        env:
          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
          STATIC_FILES_BUCKET_NAME: myStaticBucket

Any ideas?

As I thought. I tried to copy the same file with a different name and push it again and now it gets recognized passing the validation. 

I guess this is a bug.

Sorry for the monologue =)

4 Likes

I’ve got the same problem. 

Is this a bug from GitHub’s actions? 

> Is this a bug from GitHub’s actions? 

I think so

this isn’t a bug. you just (temporarily) had a syntax error in your YAML.

- uses: chrislennon/action-aws-cli@v1.1
- name: package and deploy cloudformation template

needed to be

- uses: chrislennon/action-aws-cli@v1.1
   name: package and deploy cloudformation template

I don’t think so, I am using the same template.

I am not sure the one you posted is correct: https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions

It’s a bug. When github actions throws an error, usually syntax related, most the time the “actions” tab will not notice the update to your file until you’ve renamed it. This seems to be particularly true when a job is running.

I have exactly same problem. I had a syntax error in the .yml workflow file.
image
I fixed it and pushed the changes but the GitHub actions engine did not notice my change. When I opened the GitHub editor, the fix was there.

Edit: it turned out that because I had some entries in on.<push|pull_request>.paths, the workflow was only updated after I did some changes in that path.