Skip to content

Conversation

@JeremieGince
Copy link
Owner

This pull request introduces several updates to the CI/CD workflows, testing infrastructure, and codebase to enhance automation, compatibility, and maintainability. Key changes include improvements to GitHub Actions workflows for building, testing, and publishing, as well as refactoring the run_pytests.py script to use argparse for better command-line argument handling.

CI/CD Workflow Improvements:

  • Build and Publish Updates:

    • Removed redundant steps for pushing dist artifacts and added a step to validate the distribution with twine check.
    • Introduced a step to publish the distribution to PyPI using pypa/gh-action-pypi-publish.
    • Added automatic merging of the main branch into the dev branch after successful builds.
  • Documentation Workflow Simplification:

    • Removed the PyPI publishing step from the documentation workflow, as it is now handled in the build workflow.
    • Simplified dependency installation by removing unnecessary wheel and build dependencies.

Testing Enhancements:

  • Matrix Testing:

    • Added support for testing across multiple Python versions (3.10, 3.11, 3.12, 3.13) in both Ubuntu and Windows workflows. [1] [2]
  • Code Coverage and Build Validation:

    • Integrated a code coverage step using orgoro/coverage with strict thresholds for overall and new code coverage.
    • Added a test build step to validate the package before publishing.

Codebase Refactoring:

  • Refactored run_pytests.py:

    • Replaced the custom argument parsing logic with argparse for improved readability and maintainability.
    • Added support for optional arguments like --save_report and --cov-report.
  • Other Updates:

    • Updated setup.py to drop support for Python 3.9 and explicitly support Python 3.10.
    • Refactored __main__.py to define a proper argument parser using argparse.

Configuration Adjustments:

  • Removed Redundant Test Configurations:
    • Deleted unused pytest options (--cov, --no-cov, --durations) from pyproject.toml.

@github-actions
Copy link
Contributor

github-actions bot commented Jun 3, 2025

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
21 21 100% 98% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
src/python_template/init.py 100% 🟢
src/python_template/main.py 100% 🟢
TOTAL 100% 🟢

updated for commit: bfeff42 by action🐍

@JeremieGince JeremieGince merged commit faddc9d into main Jun 3, 2025
8 checks passed
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