Skip to content

Commit 6f37281

Browse files
authored
Merge pull request #67 from RayCarterLab/v2.2
release: prepare ExcelAlchemy 2.2.7
2 parents 93ed22e + dee5649 commit 6f37281

46 files changed

Lines changed: 1596 additions & 135 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,11 @@ jobs:
110110
- name: Run smoke scripts
111111
if: matrix.python-version == '3.14'
112112
run: |
113+
uv pip install fastapi httpx python-multipart
113114
uv run python scripts/smoke_package.py
114115
uv run python scripts/smoke_examples.py
115116
uv run python scripts/generate_example_output_assets.py
117+
uv run python scripts/smoke_docs_assets.py
116118
117119
- name: Upload coverage artifact
118120
if: always() && matrix.python-version == '3.14'

.github/workflows/python-publish.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,19 +56,23 @@ jobs:
5656
run: |
5757
uv venv .pkg-smoke-wheel --python 3.14
5858
uv pip install --python .pkg-smoke-wheel/bin/python dist/*.whl
59+
uv pip install --python .pkg-smoke-wheel/bin/python fastapi httpx python-multipart
5960
.pkg-smoke-wheel/bin/python -c "import excelalchemy; print(excelalchemy.__version__)"
6061
.pkg-smoke-wheel/bin/python scripts/smoke_package.py
6162
.pkg-smoke-wheel/bin/python scripts/smoke_examples.py
6263
.pkg-smoke-wheel/bin/python scripts/generate_example_output_assets.py
64+
.pkg-smoke-wheel/bin/python scripts/smoke_docs_assets.py
6365
6466
- name: Smoke test source distribution installation
6567
run: |
6668
uv venv .pkg-smoke-sdist --python 3.14
6769
uv pip install --python .pkg-smoke-sdist/bin/python dist/*.tar.gz
70+
uv pip install --python .pkg-smoke-sdist/bin/python fastapi httpx python-multipart
6871
.pkg-smoke-sdist/bin/python -c "import excelalchemy; print(excelalchemy.__version__)"
6972
.pkg-smoke-sdist/bin/python scripts/smoke_package.py
7073
.pkg-smoke-sdist/bin/python scripts/smoke_examples.py
7174
.pkg-smoke-sdist/bin/python scripts/generate_example_output_assets.py
75+
.pkg-smoke-sdist/bin/python scripts/smoke_docs_assets.py
7276
7377
- name: Set artifact metadata
7478
id: artifact-meta

CHANGELOG.md

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,70 @@ All notable changes to this project will be documented in this file.
44

55
The format is inspired by Keep a Changelog and versioned according to PEP 440.
66

7+
## [2.2.7] - 2026-04-04
8+
9+
This release continues the stable 2.x line with stronger API-facing result
10+
payloads, a more complete FastAPI reference application, harder install-time
11+
smoke verification, and more consistent codec diagnostics.
12+
13+
### Added
14+
15+
- Added `docs/api-response-cookbook.md` with copyable success, data-invalid,
16+
and header-invalid response shapes for backend integrations
17+
- Added request and response contract modules for the FastAPI reference app
18+
under `examples/fastapi_reference/schemas.py` and
19+
`examples/fastapi_reference/responses.py`
20+
- Added `scripts/smoke_docs_assets.py` to verify showcase assets and critical
21+
result-object/showcase documentation entry points
22+
- Added logger consistency tests for codec fallback diagnostics
23+
24+
### Changed
25+
26+
- Extended `ImportResult`, `CellErrorMap`, and `RowIssueMap` payload guidance
27+
so `code`, `message_key`, `message`, and `display_message` have clearer and
28+
more stable frontend-facing roles
29+
- Strengthened `CellErrorMap` and `RowIssueMap` with summary helpers for
30+
aggregation by field, row, and machine-readable code
31+
- Made `ImportResult.to_api_payload()` a stable top-level integration surface
32+
for success, data-invalid, and header-invalid responses
33+
- Expanded the FastAPI reference app into a more copyable minimal application
34+
with request schema, response schema, structured response builder, and
35+
cookbook-aligned payloads
36+
- Hardened release smoke verification so installed-package checks now cover:
37+
- successful imports
38+
- failed imports
39+
- structured error payloads
40+
- example asset generation
41+
- result-object and showcase docs
42+
- FastAPI reference HTTP behavior after dependency installation
43+
- Unified codec fallback logging under the `excelalchemy.codecs` logger and
44+
aligned warning wording across option, parse, and render fallbacks
45+
46+
### Fixed
47+
48+
- Fixed the runnable FastAPI example and the FastAPI reference app so their
49+
runtime type annotations work correctly when optional web dependencies are
50+
actually installed
51+
- Fixed stale integration-test expectations after the improved business-facing
52+
validation messages landed
53+
54+
### Compatibility Notes
55+
56+
- No public import or export workflow API was removed in this release
57+
- `ImportResult`, `CellErrorMap`, and `RowIssueMap` remain the stable public
58+
result objects for 2.x integrations
59+
- `storage=...` remains the recommended 2.x backend configuration path
60+
- Legacy built-in Minio fields remain part of the 2.x compatibility surface
61+
62+
### Release Summary
63+
64+
- API response payloads are easier to consume from frontends and backend
65+
clients
66+
- the FastAPI reference project now looks more like a copyable minimal app
67+
- release smoke checks now verify docs, assets, failed-import payloads, and
68+
installed FastAPI integrations
69+
- codec diagnostics are more consistent and easier to filter by logger
70+
771
## [2.2.6] - 2026-04-04
872

973
This release continues the stable 2.x line with stronger consumer-facing

README-pypi.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ ExcelAlchemy turns Pydantic models into typed workbook contracts:
1010
- render workbook-facing output in `zh-CN` or `en`
1111
- keep storage pluggable through `ExcelStorage`
1212

13-
The current stable release is `2.2.6`, which continues the 2.x line with stronger result-object guidance, a copyable FastAPI reference project, more robust smoke verification, and clearer codec fallback diagnostics.
13+
The current stable release is `2.2.7`, which continues the 2.x line with stronger API-facing result payloads, a more complete FastAPI reference app, harder install-time smoke verification, and more consistent codec diagnostics.
1414

15-
[GitHub Repository](https://github.com/RayCarterLab/ExcelAlchemy) · [Full README](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/README.md) · [Getting Started](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/getting-started.md) · [Result Objects](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/result-objects.md) · [Examples Showcase](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/examples-showcase.md) · [Architecture](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/architecture.md) · [Migration Notes](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/MIGRATIONS.md)
15+
[GitHub Repository](https://github.com/RayCarterLab/ExcelAlchemy) · [Full README](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/README.md) · [Getting Started](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/getting-started.md) · [Result Objects](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/result-objects.md) · [API Response Cookbook](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/api-response-cookbook.md) · [Examples Showcase](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/examples-showcase.md) · [Architecture](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/architecture.md) · [Migration Notes](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/MIGRATIONS.md)
1616

1717
## Screenshots
1818

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
![Lint](https://img.shields.io/badge/lint-ruff-D7FF64)
77
![Typing](https://img.shields.io/badge/typing-pyright-2C6BED)
88

9-
[中文 README](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/README_cn.md) · [About](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/ABOUT.md) · [Getting Started](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/getting-started.md) · [Result Objects](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/result-objects.md) · [Architecture](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/architecture.md) · [Examples Showcase](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/examples-showcase.md) · [Public API](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/public-api.md) · [Locale Policy](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/locale.md) · [Changelog](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/CHANGELOG.md) · [Migration Notes](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/MIGRATIONS.md)
9+
[中文 README](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/README_cn.md) · [About](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/ABOUT.md) · [Getting Started](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/getting-started.md) · [Result Objects](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/result-objects.md) · [API Response Cookbook](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/api-response-cookbook.md) · [Architecture](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/architecture.md) · [Examples Showcase](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/examples-showcase.md) · [Public API](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/public-api.md) · [Locale Policy](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/docs/locale.md) · [Changelog](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/CHANGELOG.md) · [Migration Notes](https://github.com/RayCarterLab/ExcelAlchemy/blob/main/MIGRATIONS.md)
1010

1111
ExcelAlchemy is a schema-driven Python library for Excel import and export workflows.
1212
It turns Pydantic models into typed workbook contracts: generate templates, validate uploads, map failures back to rows
@@ -16,7 +16,7 @@ This repository is also a design artifact.
1616
It documents a series of deliberate engineering choices: `src/` layout, Pydantic v2 migration, pandas removal,
1717
pluggable storage, `uv`-based workflows, and locale-aware workbook output.
1818

19-
The current stable release is `2.2.6`, which continues the ExcelAlchemy 2.x line with stronger result-object guidance, a copyable FastAPI reference project, more robust release smoke verification, and clearer codec fallback diagnostics.
19+
The current stable release is `2.2.7`, which continues the ExcelAlchemy 2.x line with stronger API-facing result payloads, a more complete FastAPI reference app, harder install-time smoke verification, and more consistent codec diagnostics.
2020

2121
## At a Glance
2222

README_cn.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
ExcelAlchemy 是一个面向 Excel 导入导出的 schema-first Python 库。
66
它的核心思路不是“读写表格文件”,而是“把 Excel 当成一种带约束的业务契约”。
77

8-
当前稳定发布版本是 `2.2.6`,它在稳定的 ExcelAlchemy 2.x 线上继续加强了结果对象与接入说明、可复制的 FastAPI 参考项目、更稳的 release smoke 验证,以及更清晰的 codec fallback 诊断信息。
8+
当前稳定发布版本是 `2.2.7`,它在稳定的 ExcelAlchemy 2.x 线上继续加强了 API 结果载荷、FastAPI 参考应用、安装后真实可用的 release smoke 验证,以及更一致的 codec 诊断信息。
99

1010
你用 Pydantic 模型定义结构,用 `FieldMeta` 定义 Excel 元数据,用显式的导入/导出流程去完成模板生成、数据校验、错误回写和后端集成。
1111

0 commit comments

Comments
 (0)