Skip to content

Patch badge#14

Closed
swo wants to merge 5 commits into
mainfrom
swo_badge2
Closed

Patch badge#14
swo wants to merge 5 commits into
mainfrom
swo_badge2

Conversation

@swo

@swo swo commented Aug 14, 2025

Copy link
Copy Markdown
Collaborator

To do

Solution 1: The badge only gets added when it's updated.

Solution 2: The badge gets committed once per pull to main. But then it has to happen after everything else, and not trigger versioning?

Done

  • Create a common setup-poetry action
  • Separate the pytest and badge coverage actions, since they don't depend on each other now

steps:
- name: Build badge
run: |
poetry run coverage-badge -f -o docs/assets/badges/coverage.svg

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the one issue this might have is that the coverage badge is generating a badge using the coverage report from the testing run, which I don't think it will have access to if this is a different job.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh interesting. But where does the test result report get written?

My quick read is that coverage-badge calls Coverage.py, which in turn makes its own call to pytest? https://coverage.readthedocs.io/en/7.10.3/

@swo

swo commented Aug 14, 2025

Copy link
Copy Markdown
Collaborator Author

Closing in favor of #15 and other fixes

@swo swo closed this Aug 14, 2025
@swo
swo deleted the swo_badge2 branch August 14, 2025 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants