Skip to content

Commit 6d57396

Browse files
committed
Finalize docling-core pinning, fix mypy
Signed-off-by: Christoph Auer <[email protected]>
1 parent 109f864 commit 6d57396

File tree

3 files changed

+19
-22
lines changed

3 files changed

+19
-22
lines changed

Diff for: docling_parse/pdf_parser.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
from docling_core.types.doc.page import (
1111
BitmapResource,
1212
BoundingRectangle,
13+
Coord2D,
1314
ParsedPdfDocument,
1415
PdfLine,
1516
PdfMetaData,
@@ -301,9 +302,9 @@ def _to_lines(self, data: dict) -> List[PdfLine]:
301302
i0: int = item["i"][l + 0]
302303
i1: int = item["i"][l + 1]
303304

304-
points: List[Tuple[float, float]] = []
305+
points: List[Coord2D] = []
305306
for k in range(i0, i1):
306-
points.append((item["x"][k], item["y"][k]))
307+
points.append(Coord2D(item["x"][k], item["y"][k]))
307308

308309
line = PdfLine(
309310
index=ind,

Diff for: poetry.lock

+15-19
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ tabulate = ">=0.9.0,<1.0.0"
5252
pywin32 = { version = ">=305", markers = "sys_platform == 'win32'" }
5353
pillow = ">=10.0.0,<12.0.0"
5454
pydantic = "^2.0.0"
55-
docling-core = {git = "https://github.com/DS4SD/docling-core", rev = "cau/docling-parse-types"}
55+
docling-core = "^2.23.0"
5656

5757
[tool.poetry.group.dev.dependencies]
5858
pytest = "^7.4.2"

0 commit comments

Comments
 (0)