Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding duplicate comment when deleting a preview #13

Closed
stephenmathieson opened this issue Jan 28, 2022 · 3 comments · May be fixed by #14
Closed

Adding duplicate comment when deleting a preview #13

stephenmathieson opened this issue Jan 28, 2022 · 3 comments · May be fixed by #14
Labels

Comments

@stephenmathieson
Copy link

First off, thank you for this! Getting deployment previews on OSS repos is super helpful!


Describe the bug
The action adds a comment when deleting a preview.

To Reproduce

name: PR preview cleanup

on:
  pull_request:
    types: [closed]

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - id: setenv
        run: echo "::set-output name=BRANCH_NAME::$(echo ${GITHUB_HEAD_REF})"
      - uses: yinlinchen/amplify-preview-actions@master
        with:
          branch_name: ${{ steps.setenv.outputs.BRANCH_NAME }}
          amplify_command: delete
        env:
          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          AmplifyAppId: d1gko6en628vir
          AWS_REGION: us-east-1

Expected behavior
The preview is deleted, no comment is created.

Screenshots
Duplicate comment (the 2nd is result of deletion of a preview):

image

Desktop (please complete the following information):

  • OS: macOS

Additional context

stephenmathieson added a commit to stephenmathieson/amplify-preview-actions that referenced this issue Jan 28, 2022
@yinlinchen
Copy link
Owner

@stephenmathieson thanks for reporting this. I didn't see this issue happened in our project. It is our setting for your reference: https://github.com/VTUL/dlp-access/blob/dev/.github/workflows/merge.yml
Screen Shot 2022-02-01 at 6 25 37 PM

@github-actions
Copy link

This issue is stale because it has been open for 60 days with no activity.

@github-actions github-actions bot added the stale label Feb 25, 2023
@github-actions
Copy link

This issue was closed because it has been inactive for 14 days since being marked as stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants