@ai-devtools/dbspec-windows-x64 1.5.12 → 1.6.1

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.
Files changed (38) hide show
  1. package/bin/dbspec/_internal/_asyncio.pyd +0 -0
  2. package/bin/dbspec/_internal/_bz2.pyd +0 -0
  3. package/bin/dbspec/_internal/_ctypes.pyd +0 -0
  4. package/bin/dbspec/_internal/_decimal.pyd +0 -0
  5. package/bin/dbspec/_internal/_elementtree.pyd +0 -0
  6. package/bin/dbspec/_internal/_hashlib.pyd +0 -0
  7. package/bin/dbspec/_internal/_lzma.pyd +0 -0
  8. package/bin/dbspec/_internal/_multiprocessing.pyd +0 -0
  9. package/bin/dbspec/_internal/_overlapped.pyd +0 -0
  10. package/bin/dbspec/_internal/_queue.pyd +0 -0
  11. package/bin/dbspec/_internal/_socket.pyd +0 -0
  12. package/bin/dbspec/_internal/_sqlite3.pyd +0 -0
  13. package/bin/dbspec/_internal/_ssl.pyd +0 -0
  14. package/bin/dbspec/_internal/_uuid.pyd +0 -0
  15. package/bin/dbspec/_internal/_wmi.pyd +0 -0
  16. package/bin/dbspec/_internal/_zoneinfo.pyd +0 -0
  17. package/bin/dbspec/_internal/base_library.zip +0 -0
  18. package/bin/dbspec/_internal/dbspec.egg-info/PKG-INFO +1 -1
  19. package/bin/dbspec/_internal/libcrypto-3.dll +0 -0
  20. package/bin/dbspec/_internal/libssl-3.dll +0 -0
  21. package/bin/dbspec/_internal/pyexpat.pyd +0 -0
  22. package/bin/dbspec/_internal/pyproject.toml +1 -1
  23. package/bin/dbspec/_internal/python313.dll +0 -0
  24. package/bin/dbspec/_internal/select.pyd +0 -0
  25. package/bin/dbspec/_internal/sqlalchemy/engine/_processors_cy.cp313-win_amd64.pyd +0 -0
  26. package/bin/dbspec/_internal/sqlalchemy/engine/_result_cy.cp313-win_amd64.pyd +0 -0
  27. package/bin/dbspec/_internal/sqlalchemy/engine/_row_cy.cp313-win_amd64.pyd +0 -0
  28. package/bin/dbspec/_internal/sqlalchemy/engine/_util_cy.cp313-win_amd64.pyd +0 -0
  29. package/bin/dbspec/_internal/sqlalchemy/sql/_cache_key_cy.cp313-win_amd64.pyd +0 -0
  30. package/bin/dbspec/_internal/sqlalchemy/sql/_util_cy.cp313-win_amd64.pyd +0 -0
  31. package/bin/dbspec/_internal/sqlalchemy/util/_collections_cy.cp313-win_amd64.pyd +0 -0
  32. package/bin/dbspec/_internal/sqlalchemy/util/_immutabledict_cy.cp313-win_amd64.pyd +0 -0
  33. package/bin/dbspec/_internal/sqlite3.dll +0 -0
  34. package/bin/dbspec/_internal/src/resources/sqlalchemy_templates/README.md +2 -0
  35. package/bin/dbspec/_internal/src/resources/sqlalchemy_templates/model.py.j2 +17 -6
  36. package/bin/dbspec/_internal/unicodedata.pyd +0 -0
  37. package/bin/dbspec/dbspec.exe +0 -0
  38. package/package.json +1 -1
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dbspec
3
- Version: 1.5.12
3
+ Version: 1.6.1
4
4
  Summary: DBSpec: CLI/TUI for database design (Excel as DSL)
5
5
  Requires-Python: >=3.11
6
6
  Description-Content-Type: text/markdown
Binary file
Binary file
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "dbspec"
7
- version = "1.5.12"
7
+ version = "1.6.1"
8
8
  description = "DBSpec: CLI/TUI for database design (Excel as DSL)"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.11"
Binary file
Binary file
Binary file
@@ -68,3 +68,5 @@ Jinja-параметров, зависящий только от стандар
68
68
  от исходников или пакета DBSpec. Ресурс входит в существующее пакетирование `*.j2`
69
69
  и сборку frozen CLI; изменения проверяются тестами scanner/comparator и
70
70
  изолированным subprocess без site-packages.
71
+
72
+ В 1.6.0 IndexContext содержит directions (ASC/DESC/пустая строка) в порядке columns и has_directions. Для направленных unique indexes используйте Index(unique=True), а не UniqueConstraint. Направления передаются методами SQLAlchemy .asc()/.desc(). Проектные шаблоны обновляются отдельно.
@@ -100,7 +100,7 @@ from ..{{ common_dir_name }}.base import metadata
100
100
  ),
101
101
  {% endif %}
102
102
  {% for check in table.check_constraints %}
103
- CheckConstraint("{{ check.expression | replace('"', '\\"') }}", name="{{ check.name }}"),
103
+ CheckConstraint({{ check.expression | py_repr }}, name={{ check.name | py_repr }}),
104
104
  {% endfor %}
105
105
  {% for constraint in table.unique_constraints %}
106
106
  UniqueConstraint(
@@ -114,7 +114,7 @@ from ..{{ common_dir_name }}.base import metadata
114
114
  ),
115
115
  {% endfor %}
116
116
  {% for idx in table.indexes %}
117
- {% if idx.unique and not idx.where %}
117
+ {% if idx.unique and not idx.where and not idx.has_directions %}
118
118
  UniqueConstraint(
119
119
  {% for c in idx.columns %}
120
120
  "{{ c }}",
@@ -129,11 +129,11 @@ from ..{{ common_dir_name }}.base import metadata
129
129
  {% endif %}
130
130
  )
131
131
  {% for idx in table.indexes %}
132
- {% if idx.where or not idx.unique %}
132
+ {% if idx.where or not idx.unique or idx.has_directions %}
133
133
  Index(
134
134
  "{{ idx.name }}",
135
135
  {% for c in idx.columns %}
136
- {{ table.module_name }}.c.{{ c }},
136
+ {{ table.module_name }}.c[{{ c | py_repr }}]{% if idx.directions[loop.index0] %}.{{ idx.directions[loop.index0] | lower }}(){% endif %},
137
137
  {% endfor %}
138
138
  {% if idx.unique %}
139
139
  unique=True,
@@ -225,7 +225,7 @@ class {{ table.class_name }}({{ base_class }}):
225
225
  ),
226
226
  {% endif %}
227
227
  {% for check in table.check_constraints %}
228
- CheckConstraint("{{ check.expression | replace('"', '\\"') }}", name="{{ check.name }}"),
228
+ CheckConstraint({{ check.expression | py_repr }}, name={{ check.name | py_repr }}),
229
229
  {% endfor %}
230
230
  {% for constraint in table.unique_constraints %}
231
231
  UniqueConstraint(
@@ -239,7 +239,18 @@ class {{ table.class_name }}({{ base_class }}):
239
239
  ),
240
240
  {% endfor %}
241
241
  {% for idx in table.indexes %}
242
- {% if idx.where and idx.unique %}
242
+ {% if idx.has_directions %}
243
+ Index(
244
+ {{ idx.name | py_repr }},
245
+ {% for c in idx.columns %}
246
+ {% if idx.directions[loop.index0] %}column({{ c | py_repr }}).{{ idx.directions[loop.index0] | lower }}(){% else %}{{ c | py_repr }}{% endif %},
247
+ {% endfor %}
248
+ unique={{ 'True' if idx.unique else 'False' }},
249
+ {% if idx.where %}
250
+ postgresql_where=text({{ idx.where | py_repr }}),
251
+ {% endif %}
252
+ ),
253
+ {% elif idx.where and idx.unique %}
243
254
  Index(
244
255
  "{{ idx.name }}",
245
256
  {% for c in idx.columns %}
Binary file
package/package.json CHANGED
@@ -24,5 +24,5 @@
24
24
  "publishConfig": {
25
25
  "access": "public"
26
26
  },
27
- "version": "1.5.12"
27
+ "version": "1.6.1"
28
28
  }