Skip to content

Add Pre-Commit & GitHub actions#1

Merged
matthewygf merged 38 commits intomainfrom
github_actions
Jan 1, 2026
Merged

Add Pre-Commit & GitHub actions#1
matthewygf merged 38 commits intomainfrom
github_actions

Conversation

@matthewygf
Copy link
Copy Markdown
Owner

@matthewygf matthewygf commented Dec 29, 2025

This pull request introduces several key improvements to the development workflow and code quality enforcement for the project. The main changes include adding a comprehensive CI workflow for linting and testing on Ascend 910B hardware, introducing pre-commit hooks for code quality, and enhancing Python code style consistency. Additionally, minor documentation and code formatting updates are included.

CI/CD and Code Quality Automation:

  • Added a new GitHub Actions workflow (.github/workflows/build-and-test.yml) to run lint checks and execute unit tests on Ascend 910B hardware using a containerized environment, with automated log upload and test reporting.
  • Removed the old build check workflow for Ascend 910B, consolidating CI processes into the new workflow. (.github/workflows/build-a2-check.yml)

Pre-commit Hooks and Linting:

  • Introduced a .pre-commit-config.yaml file to enable automated checks for SPDX headers, Python import sorting (isort), code formatting (ruff), spell checking (codespell), C++ formatting (clang-format), and type checking (mypy) from upstream.

Code Style and Documentation:

  • Improved code formatting, style consistency, and SPDX license compliance in benchmark/v1/rag/analysis.py and benchmark/v1/rag/rag.py, including import reordering, string normalization, and better argument parsing.
  • Fixed minor spelling errors in the README.md for improved clarity.

These changes collectively improve the project's code quality, enforce best practices, and streamline CI for both development and deployment.

@matthewygf matthewygf merged commit 318f48e into main Jan 1, 2026
2 of 3 checks passed
@matthewygf matthewygf deleted the github_actions branch January 1, 2026 19:17
matthewygf added a commit that referenced this pull request Jan 5, 2026
* Add build workflow check

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Update Dockerfile paths in build workflow

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Enable submodules in build workflow

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Add Pre-Commit & GitHub actions (#1)

* Add Pre-commit lint & build test workflow action
---------

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Update build-and-test.yml

- because the host-ip variable cannot work here yet, so temporarily pass for the bridgeip

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Add pull-requests permission to workflow

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Remove test report publishing step

Removed the test report publishing step from the workflow.

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Add workflow to publish test results

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* enhance reports xml

* Fix formatting in build-and-test workflow

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Fix formatting in report-test-results.yml

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

* Fix error message formatting in managed_mem.cpp

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>

---------

Signed-off-by: Matthew Yeung <yyygggfff@hotmail.com>
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.

1 participant