PavanMudigonda / jacoco-reporter

GitHub Action to Publish JaCoCo Format Code Coverage XML and attach it to the Workflow Run as a Check Run. Also can enforce Coverage Quality Gate.
https://linkedin.com/in/PavanMudigonda
MIT License
63 stars 7 forks source link

Regression: build failure when upgrading from v4.9 to v5.0 #59

Closed opwvhk closed 4 months ago

opwvhk commented 6 months ago

Regression Summary

The GitHub Action below works with v4.9, but fails with v5.0.

The action:

name: CI
on:
  push:
    branches: [ main ]
  pull_request:
    branches: [ main ]
  workflow_dispatch:
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - name: Publish Test Coverage Results
        # noinspection SpellCheckingInspection
        uses: PavanMudigonda/jacoco-reporter@v5.0
        with:
          coverage_results_path: 'target/site/jacoco/jacoco.xml'
          coverage_report_title: 'Test Coverage Results'
          coverage_report_name: 'Test-Coverage-Results'
          github_token: ${{ secrets.GITHUB_TOKEN }}

The error:

Error: Unable to process file command 'output' successfully.
Error: Invalid format '# Coverage Report: Test Coverage Results'

With v4.9, the build successfully publishes the code coverage results.

opwvhk commented 6 months ago

Based on not solving the error by changing the report name from 'Test Coverage Results' to 'Test-Coverage-Results', my guess is that this is related to the report title.

However, I do not understand the error message, nor why this causes problems.

PavanMudigondaTR commented 6 months ago

Please do not use v5.0 as its pre-release which i am still testing and fixing. thanks for bringing this to my notice.

opwvhk commented 6 months ago

Clear. Thank you.

One request though: can you please make a note of this at the top of the readme, or (probably better) add it to the bug template?

The reason is that v5.0 is deployed to Maven Central, and dependency bots trigger people to upgrade. If they (like me) open a ticket, they'll see immediately you're already fixing the issues.

PavanMudigondaTR commented 4 months ago

@opwvhk As requested, i have added v5.0 which is the latest version at top of README.md to resolve this issue. Closing the issue now. thanks for reporting your concern !

image