Pin mcp<2.0.0 — mcp 2.0 removed the Server decorator API #35
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| # 只跑離線檢查(pytest 全 mock、smoke 用假 token、build_instructions 純本地)。 | |
| # regression/runner.py 會打 live API、需要 FINMIND_TOKEN,故不放 CI,由發版前人工跑。 | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # hatch-vcs 需要 tags/history 才能決定版本(build 本套件時) | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| enable-cache: true | |
| - name: Install dependencies | |
| run: uv sync --extra dev | |
| - name: Unit tests (mocked, offline) | |
| run: uv run pytest -q | |
| - name: Stdio smoke test | |
| run: uv run python smoke.py | |
| - name: ChatGPT instructions build (must stay under the 8000-char Action limit) | |
| run: uv run python chatgpt/build_instructions.py | |
| doc-sync: | |
| # Fail the build when a dataset documented in FinMind-Doc is missing from | |
| # knowledge/datasets.md (the catalog silently drifting behind the docs is | |
| # what let several datasets go unlisted for months). Only needs stdlib, so | |
| # no uv/deps — just checkout both public repos and diff. | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout FinMind-MCP | |
| uses: actions/checkout@v4 | |
| - name: Checkout FinMind-Doc (public) | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: FinMind/FinMind-Doc | |
| path: FinMind-Doc | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Catalog vs FinMind-Doc sync check | |
| run: python scripts/check_doc_sync.py --doc ./FinMind-Doc |