Skip to content

Bypass memory benchmarks for documentation changes #1913

@unalmis

Description

@unalmis

I couldn't find a way to add label-based exceptions to codecov, so these types of PR's are always expected to be merged by override access.

For memory, I forgot to add this logic to the workflow, if you want you can add it in this PR. Basically add,

- name: Filter changes
        id: changes
        uses: dorny/paths-filter@v3
        with:
          filters: |
            has_changes:
              - 'desc/**'
              - 'requirements.txt'
              - 'devtools/dev-requirements.txt'
              - '.github/workflows/memory_benchmark.yml'

      - name: Check for relevant changes
        id: check_changes
        run: echo "has_changes=${{ !contains(github.event.pull_request.labels.*.name, 'only-docs-comments') && steps.changes.outputs.has_changes }}" >> $GITHUB_ENV

Before setup python step. Then add,

if: env.has_changes == 'true'

to other steps. You can look for the workflow yml's of unit/regression tests for implementation. Note: if you do it in this PR, it will probably still run for this one, but once it is merged, it will be resolved.

Once benchmarks start, it will skip actual benchmarks, it will take couple seconds.

Originally posted by @YigitElma in #1862 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1Lowest Priority, will get to eventually

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions