CadQuery / CadQuery/cadquery

`show` doesn't work in python 3.13 but works in 3.12

Open
#1,944 10 comments 0 reactions 0 assignees View on GitHub
bug pip
Dominant language
Python
Stars
5.8k
Forks
541
Avg merge
3d 2h
Merged PRs (30d)
5

Description

## To Reproduce

Making a new venv on 3.13.9 installing cadquery (pip) and running the example for show
```python
from cadquery import *
from cadquery.vis import show

w = Workplane().sphere(1).split(keepBottom=True) - Workplane().sphere(0.5)
r = w.faces('>Z').fillet(0.1)

# Show the result
show(r, alpha=0.5)
```
Throws an error, but the same procedure of creating a venv in 3.12.10, installing cadquery and running the show example works as expected.

I found it while trying to make a mixture of cadquery and sdf (like [microgen](https://github.com/3MAH/microgen)), I don't specifically need 3.13, just filling the report in case it helps.

## Backtrace

```
^CVTK not installed
Traceback (most recent call last):
File "/Users/david/Documents/code/cq2/test.py", line 1, in
from cadquery import *
File "/Users/david/Documents/code/cq2/lib/python3.13/site-packages/cadquery/__init__.py", line 11, in
from .occ_impl.shapes import (
...<9 lines>...
)
File "/Users/david/Documents/code/cq2/lib/python3.13/site-packages/cadquery/occ_impl/shapes.py", line 292, in
from OCP.IVtkOCC import IVtkOCC_Shape, IVtkOCC_ShapeMesher
ImportError: cannot import name 'IVtkOCC_Shape' from 'OCP.IVtkOCC' (/Users/david/Documents/code/cq2/lib/python3.13/site-packages/OCP/IVtkOCC/__init__.py)
```

## Environment

OS:
MaxOS 26.1
Sorry, I wasn't using conda, I was using pip.

Was CadQuery installed using Conda?:
Output of `conda list` from your active Conda environment:
```
```

Using:
Python interpreter

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.