licos-dev-sdk 0.4.4__tar.gz → 0.4.5__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.
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/DOCX.md +1 -1
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/PKG-INFO +1 -1
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/pyproject.toml +1 -1
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_inspect.py +1 -1
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_docx_inspect.py +20 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/.gitignore +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/__init__.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/_utils.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/archive.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/chart.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/data.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/diagram.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_common.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_edit.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_expectations.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_layout.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_package.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_preservation.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_structure.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_table.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_table_actions.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_read.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_table_export.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/image.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/model.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/observability.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/pdf_inspect.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/ppt_master_runtime.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/presentation.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/presentation_canvas.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/presentation_inspect.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/spreadsheet.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/spreadsheet_edit.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/spreadsheet_html.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/spreadsheet_inspect.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/web.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_document_read.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_document_spreadsheet.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_document_table_export.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_docx_structure.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_docx_table_edit.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_html_docx_features.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_model.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_observability.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_output_paths.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_ppt_master_runtime.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_presentation.py +0 -0
- {licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/tests/test_spreadsheet_html_edit.py +0 -0
|
@@ -62,7 +62,7 @@ def inspect_docx(source: str | Path, *, scope: str = "all", offset: int = 1, lim
|
|
|
62
62
|
if element.tag == W + "tbl":
|
|
63
63
|
grid = element.find(W + "tblGrid")
|
|
64
64
|
tables.append({"part": part, "row_count": len(element.findall(W + "tr")),
|
|
65
|
-
"column_count": len(grid) if grid is not None else None})
|
|
65
|
+
"column_count": len(grid.findall(W + "gridCol")) if grid is not None else None})
|
|
66
66
|
if element.tag not in {A + "blip", V + "imagedata"}:
|
|
67
67
|
continue
|
|
68
68
|
rid = element.get(R + "embed") or element.get(R + "link") or element.get(R + "id")
|
|
@@ -82,6 +82,26 @@ def test_incomplete_toc_and_external_or_missing_image_relationships(tmp_path):
|
|
|
82
82
|
assert [image['status'] for image in report['images']['items']] == ['external', 'missing_relationship']
|
|
83
83
|
|
|
84
84
|
|
|
85
|
+
def test_table_grid_revisions_do_not_count_as_current_columns(tmp_path):
|
|
86
|
+
path = tmp_path / 'tracked-table.docx'
|
|
87
|
+
doc = Document()
|
|
88
|
+
table = doc.add_table(rows=3, cols=2)
|
|
89
|
+
change = OxmlElement('w:tblGridChange')
|
|
90
|
+
change.set(qn('w:id'), '1')
|
|
91
|
+
previous = OxmlElement('w:tblGrid')
|
|
92
|
+
previous.append(OxmlElement('w:gridCol'))
|
|
93
|
+
change.append(previous)
|
|
94
|
+
table._tbl.tblGrid.append(change)
|
|
95
|
+
doc.save(path)
|
|
96
|
+
original = path.read_bytes()
|
|
97
|
+
assert len(Document(path).tables[0].columns) == 2
|
|
98
|
+
report = inspect_docx(path, scope='tables')
|
|
99
|
+
assert report['tables']['items'] == [
|
|
100
|
+
{'part': 'word/document.xml', 'row_count': 3, 'column_count': 2},
|
|
101
|
+
]
|
|
102
|
+
assert path.read_bytes() == original
|
|
103
|
+
|
|
104
|
+
|
|
85
105
|
def test_batch_file_assertions_resolve_from_explicit_base_and_keep_exact_text(tmp_path, monkeypatch):
|
|
86
106
|
path = tmp_path / 'report.docx'
|
|
87
107
|
text = ' 中文🙂\tA\n' * 90 + ' '
|
|
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
|
{licos_dev_sdk-0.4.4 → licos_dev_sdk-0.4.5}/src/licos_dev_sdk/document_docx_table_actions.py
RENAMED
|
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
|