Skip to content

Commit 85596cb

Browse files
committed
test: enable kubernetes tests for python-language-pdf2parquet
also updates to latest from data-prep-kit Signed-off-by: Nick Mitchell <[email protected]>
1 parent 59913a7 commit 85596cb

File tree

8 files changed

+219
-88
lines changed

8 files changed

+219
-88
lines changed

pkg/be/local/shell/ok.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ func isCompatibleImage(image string) bool {
2020
func IsCompatible(c llir.ShellComponent) error {
2121
switch {
2222
case c.Application.Spec.Image != "" && !isCompatibleImage(c.Application.Spec.Image):
23-
return fmt.Errorf("Unable to target the local backend because a component '%s' needs to run in a container: %s", c.C(), c.Application.Spec.Image)
23+
if slices.IndexFunc(c.Application.Spec.Needs, func(need hlir.Needs) bool { return need.Requirements != "" }) < 0 {
24+
return fmt.Errorf("Unable to target the local backend because a component '%s' needs to run in a container: %s", c.C(), c.Application.Spec.Image)
25+
}
2426

2527
case c.Application.Spec.SecurityContext.RunAsUser != 0 ||
2628
c.Application.Spec.SecurityContext.RunAsGroup != 0 ||

tests/tests/python-language-pdf2parquet/pail/app.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ metadata:
55
spec:
66
image: docker.io/python:3.12
77
command: python3 ./main.py
8+
minSize: sm
9+
env:
10+
USE_NNPACK: '0' # otherwise torch fails with "Could not initialize NNPACK! Reason: Unsupported hardware" on ARM (lack of AVX instructions)
811
needs:
912
- name: python
1013
version: latest

tests/tests/python-language-pdf2parquet/pail/data/requirements.txt

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
docling-core==1.3.0
2-
docling-ibm-models==1.1.7
3-
deepsearch-glm==0.21.0
4-
docling==1.11.0
1+
docling-core==2.3.0
2+
docling-ibm-models==2.0.3
3+
deepsearch-glm==0.26.1
4+
docling==2.3.1
55
filetype >=1.2.0, <2.0.0
66

77
# we can probably update to 18+, but we will have to re-generate expected output as pyarrow 18 seems to have resulted in a binary format change

0 commit comments

Comments
 (0)