CodelyTV / pr-size-labeler

🏷 Visualize and optionally limit the size of your Pull Requests
https://github.com/marketplace/actions/pull-request-size-labeler
MIT License
336 stars 57 forks source link

Duplicated labels when PR is updated #32

Open Shudy opened 2 years ago

Shudy commented 2 years ago

When a PR is updated with a commit and the number of modified lines changes, the GHAction applies the label to the PR, however it does not remove the old label and adds the new label of the corresponding size.

Actually the action is quite simple:

on:
  pull_request:
jobs:
  tag_pr_size:
    runs-on: ubuntu-latest
    name: Label the PR size
    steps:
      - uses: codelytv/pr-size-labeler@v1
        with:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          xs_max_size: '10'
          s_max_size: '30'
          m_max_size: '100'
          l_max_size: '500'
          message_if_xl: >
            'This PR exceeds the recommended size of 500 lines.
            Please make sure you are NOT addressing multiple issues with one PR.’

Examples:

name: Label PR Size

Captura de pantalla 2021-10-19 a las 16 08 39 Captura de pantalla 2021-10-19 a las 16 09 04

Thanks for the work!

adrianjost commented 1 year ago

duplicate of https://github.com/CodelyTV/pr-size-labeler/issues/19

wpiet commented 3 weeks ago

The issue with duplicated labels still occurs. Sometimes the action removes outdated label, but here is one recent example where it has not. Is there any chance to have someone looking into it?