Skip to content

feat: add GitHub Actions CI for lint and smoke test #305

@cxhello

Description

@cxhello

Background

Currently, the project has no CI/CD pipeline configured. PRs are merged without any automated checks, which may lead to syntax errors, import chain breakage, or dependency issues going unnoticed.

Research

I investigated how similar Python SDK projects handle CI:

Project Lint Tool Python Matrix Smoke Test
boto3 (AWS SDK) ruff 3.9~3.15-dev
google-cloud-python nox + mypy 3.7~3.14
apache/dubbo-python ruff 3.9~3.13
openai-python ruff single version ✅ (examples)
nacos-sdk-go (same ecosystem) gofmt Go 1.21 ✅ (go test)

Key takeaway: ruff has become the standard lint tool for Python SDKs, and most projects run at least basic import/smoke tests across multiple Python versions.

Proposal

Add a lightweight GitHub Actions workflow with two jobs:

1. Lint

  • ruff check — catch syntax errors, unused imports, common issues
  • ruff format --check — ensure consistent code style

2. Smoke Test

  • Python version matrix: 3.9, 3.11, 3.13
  • Install dependencies from requirements.txt
  • Verify module import: import nacos (v1) and import v2.nacos (v2)
  • This ensures the dependency chain and import graph are not broken

Non-goals (for now)

  • Unit tests / integration tests (requires Nacos Server)
  • mypy type checking (v2 type hints coverage is incomplete)
  • Code coverage reporting

Happy to submit a PR if this direction is acceptable.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions