28 lines
1.4 KiB
Markdown
28 lines
1.4 KiB
Markdown
---
|
||
inclusion: fileMatch
|
||
fileMatchPattern: "**/pyproject.toml,**/config/**,**/migrations/**,**/.env*,**/seeds/**"
|
||
name: tech-full
|
||
description: 技术栈详细信息(依赖清单、DDL 基线、测试工具、种子数据)。读到配置/迁移/依赖文件时自动加载。
|
||
---
|
||
|
||
# 技术栈详细信息
|
||
|
||
## 核心依赖
|
||
- ETL:`psycopg2-binary`、`requests`、`python-dateutil`、`tzdata`、`python-dotenv`、`openpyxl`
|
||
- 后端:`fastapi`、`uvicorn[standard]`、`psycopg2-binary`、`python-dotenv`
|
||
- 管理后台:`React`、`Vite`、`Ant Design`(独立 pnpm 管理)
|
||
- 共享包:`neozqyy-shared`(workspace 内部引用)
|
||
- 测试:`pytest`、`hypothesis`
|
||
|
||
## 数据库详细
|
||
- 业务库 `zqyy_app`(用户/RBAC/任务/审批),通过 FDW 只读映射 ETL 数据
|
||
- DDL 基线:`docs/database/ddl/`(从测试库自动导出,按 schema 分文件),重新生成:`python scripts/ops/gen_consolidated_ddl.py`
|
||
- 旧 DDL / 迁移脚本已归档至 `db/_archived/ddl_baseline_2026-02-22/`
|
||
- 种子数据:`db/etl_feiqiu/seeds/`、`db/zqyy_app/seeds/`
|
||
|
||
## 测试
|
||
- ETL 单元测试:`cd apps/etl/connectors/feiqiu && pytest tests/unit`
|
||
- ETL 集成测试:`TEST_DB_DSN="..." pytest tests/integration`
|
||
- Monorepo 属性测试:`pytest tests/ -v`(根目录,hypothesis)
|
||
- 测试工具:`apps/etl/connectors/feiqiu/tests/unit/task_test_utils.py` 提供 FakeDB/FakeAPI
|