atquery 2.13.2__tar.gz → 2.13.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {atquery-2.13.2 → atquery-2.13.3}/PKG-INFO +1 -1
- {atquery-2.13.2 → atquery-2.13.3}/pyproject.toml +2 -2
- {atquery-2.13.2 → atquery-2.13.3}/pyproject.toml.orig +2 -2
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/catalog.py +4 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/erd.py +4 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/model.py +7 -1
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/parser.py +7 -1
- {atquery-2.13.2 → atquery-2.13.3}/LICENSE +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/README.md +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/aio/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/aio/engine.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/aio/query.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/api_v2.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/atquery2.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/columns.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/ddl.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/diff.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/ecd.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/main.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/migrate.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/routines.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/scenario.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/schemas.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/cli/tables.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/duckdb.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/aio.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/core.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/dump/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/dump/__main__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/dump/core.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/meta.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/pooling.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/restore/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/restore/__main__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/mysql/restore/core.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/dialect/sqlite.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/comparator.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/generator.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/git_integration.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/models.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/diff/parser.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/_toml.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/ddl.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/diff.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/errors.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/resolver.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/seed.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/ecd/skeleton.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/engine.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/factory.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/migration/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/migration/_migrator.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/migration/_protocol.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/migration/_standard.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/migration/_types.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/py.typed +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/testing/__init__.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/testing/creator.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/testing/loader.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/testing/schema.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/testing/validator.py +0 -0
- {atquery-2.13.2 → atquery-2.13.3}/src/atquery/type.py +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
[build-system]
|
|
2
|
-
requires = ["uv_build>=0.
|
|
2
|
+
requires = ["uv_build>=0.12.5,<0.13.0"]
|
|
3
3
|
build-backend = "uv_build"
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "atquery"
|
|
7
|
-
version = "2.13.
|
|
7
|
+
version = "2.13.3"
|
|
8
8
|
description = "A Python module for simplifying DBAPI usage with one-query-per-file SQL management."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
[build-system]
|
|
2
|
-
requires = ["uv_build>=0.
|
|
2
|
+
requires = ["uv_build>=0.12.5,<0.13.0"]
|
|
3
3
|
build-backend = "uv_build"
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "atquery"
|
|
7
|
-
version = "2.13.
|
|
7
|
+
version = "2.13.3"
|
|
8
8
|
description = "A Python module for simplifying DBAPI usage with one-query-per-file SQL management."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
(`- [label](#slug)`)にする(ADR-0033 3.1節)
|
|
13
13
|
- `affinities`は出力しない。`links`は`column`->`ref`の定義をそのまま文字列で列挙する
|
|
14
14
|
(参照解決の検証は行わない)
|
|
15
|
+
- `links[].kind == "enum"`(コードマスタ参照)はMermaid`erDiagram`の関係線・スタブノードの
|
|
16
|
+
どちらにも描画しない(テーブル詳細の`* **Links:**`一覧テキストには引き続き含める。仕様: ADR-0038)
|
|
15
17
|
- トグルは実装しない。すべてのセクションを展開した状態でそのまま出力する
|
|
16
18
|
- 見出しリンク一覧の各項目は各テーブル/VIEWの詳細見出しへのページ内リンク(`#<slug>`)にする
|
|
17
19
|
- テーブル/VIEW詳細の見出し(`### [<テーブル名>](#<slug>)`)は自身へのページ内リンクにする
|
|
@@ -223,6 +225,8 @@ def _mermaid_diagram_lines(
|
|
|
223
225
|
|
|
224
226
|
for table in file_tables:
|
|
225
227
|
for link in table.links:
|
|
228
|
+
if link.kind == "enum":
|
|
229
|
+
continue # コードマスタ参照は関係線を描画しない(ADR-0038)
|
|
226
230
|
link_columns = _split_columns(link.column)
|
|
227
231
|
ref_table_name, ref_column_field = _parse_ref(link.ref)
|
|
228
232
|
ref_columns = _split_columns(ref_column_field)
|
|
@@ -7,6 +7,8 @@
|
|
|
7
7
|
- `links[].ref`の参照先がツリー内で解決できない場合はエラーにせず、外部/未解決を示す
|
|
8
8
|
破線グレーのスタブノードとして描画する(ADR 3.4節、ADR-0027のADVISORY方針を踏襲)
|
|
9
9
|
- `affinities`はレイアウト(force-directed)の引力係数としてのみ使用し、エッジとして描画しない
|
|
10
|
+
- `links[].kind == "enum"`(コードマスタ参照)はエッジ・引力係数のどちらにも使わず描画を省略する
|
|
11
|
+
(FKバッジ自体は`fk`の値によらず引き続き付与する。仕様: ADR-0038)
|
|
10
12
|
- VIEWの`FROM`/`JOIN`先テーブルは`sqlglot`で抽出し、エッジとして描画せず、パネル内にテキスト列挙する
|
|
11
13
|
- `comment`・`values`はSVGネイティブの`<title>`要素でツールチップ表示する(JS不要)
|
|
12
14
|
- 大規模スキーマの計算量・レイアウト崩れ対策はツール側で作り込まない(ADR 3.8節)。
|
|
@@ -119,6 +121,8 @@ def generate_erd_svg(tables: Sequence[ResolvedTable], views: Sequence[ViewBlock]
|
|
|
119
121
|
for table in tables:
|
|
120
122
|
src_box = boxes_by_name[table.name]
|
|
121
123
|
for link in table.links:
|
|
124
|
+
if link.kind == "enum":
|
|
125
|
+
continue # コードマスタ参照はエッジ/引力を描画しない(ADR-0038)
|
|
122
126
|
ref_table, ref_column = _parse_ref(link.ref)
|
|
123
127
|
dst_box = boxes_by_name.get(ref_table)
|
|
124
128
|
if dst_box is None:
|
|
@@ -88,12 +88,18 @@ class IndexDef:
|
|
|
88
88
|
|
|
89
89
|
@dataclass(frozen=True)
|
|
90
90
|
class LinkDef:
|
|
91
|
-
"""クロスグループ参照(`links`配列の要素)。
|
|
91
|
+
"""クロスグループ参照(`links`配列の要素)。
|
|
92
|
+
|
|
93
|
+
`kind="enum"` は参照先がコード値マスタ(enum値)であることを示す分類用の属性で、
|
|
94
|
+
DDL生成には影響しない。ERD/カタログはこれを検出してエッジ描画を省略する
|
|
95
|
+
(仕様: docs/dev/adr/0038-ecd-link-kind-enum.md)。
|
|
96
|
+
"""
|
|
92
97
|
|
|
93
98
|
column: str
|
|
94
99
|
ref: str
|
|
95
100
|
fk: bool = False
|
|
96
101
|
comment: str | None = None
|
|
102
|
+
kind: str | None = None # None | "enum"
|
|
97
103
|
|
|
98
104
|
|
|
99
105
|
@dataclass(frozen=True)
|
|
@@ -181,7 +181,13 @@ def _build_table_block(path: str, parsed: dict, meta: dict) -> TableBlock:
|
|
|
181
181
|
Affinity(target=a["target"], weight=a.get("weight")) for a in meta.get("affinities", ())
|
|
182
182
|
),
|
|
183
183
|
links=tuple(
|
|
184
|
-
LinkDef(
|
|
184
|
+
LinkDef(
|
|
185
|
+
column=link["column"],
|
|
186
|
+
ref=link["ref"],
|
|
187
|
+
fk=link.get("fk", False),
|
|
188
|
+
comment=link.get("comment"),
|
|
189
|
+
kind=link.get("kind"),
|
|
190
|
+
)
|
|
185
191
|
for link in meta.get("links", ())
|
|
186
192
|
),
|
|
187
193
|
indexes=tuple(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|