docling-project / docling-project/docling-core

It looks like this PR and 2.83.0 release might have broken the docling-tools model download command:

Open
#648 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
282
Forks
214
Avg merge
2d 15h
Merged PRs (30d)
21

Description

It looks like this PR and 2.83.0 release might have broken the docling-tools model download command:

```
Traceback (most recent call last):
File "/var/lang/bin/docling-tools", line 5, in
from docling.cli.tools import app
File "/var/lang/lib/python3.12/site-packages/docling/cli/tools.py", line 3, in
from docling.cli.models import app as models_app
File "/var/lang/lib/python3.12/site-packages/docling/cli/models.py", line 13, in
from docling.utils.model_downloader import download_models
File "/var/lang/lib/python3.12/site-packages/docling/utils/model_downloader.py", line 17, in
from docling.models.stages.chart_extraction.granite_vision import (
File "/var/lang/lib/python3.12/site-packages/docling/models/stages/chart_extraction/granite_vision.py", line 25, in
from docling.models.base_model import BaseItemAndImageEnrichmentModel
File "/var/lang/lib/python3.12/site-packages/docling/models/base_model.py", line 22, in
from docling.datamodel.document import ConversionResult
File "/var/lang/lib/python3.12/site-packages/docling/datamodel/document.py", line 38, in
from docling_core.types.legacy_doc.base import (
ModuleNotFoundError: No module named 'docling_core.types.legacy_doc'
```

Unless there's a suggested upgrade/workaround?

_Originally posted by @sgottuso-bh in https://github.com/docling-project/docling-core/issues/644#issuecomment-4744310937_

Confirmed that docling-tools models download continues to work if you install docling and pin docling-core to < 2.83.0

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the docling-tools model download command with docling-core 2.83.0 and compare it with a version below 2.83.0. Read docling/cli/tools.py, docling/cli/models.py, docling/utils/model_downloader.py, and the import path in docling/datamodel/document.py. Done means the command starts without the ModuleNotFoundError and completes model downloading without requiring the reported pin.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.