Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pip install build123d is broken for version 0.8.0 and below (AttributeError: '... TopoDS_Shape' object has no attribute 'HashCode') #866

Closed
jdegenstein opened this issue Jan 13, 2025 · 9 comments
Assignees
Labels
bug Something isn't working

Comments

@jdegenstein
Copy link
Collaborator

jdegenstein commented Jan 13, 2025

Currently

pip install build123d

Will install build123d==0.8.0 and cadquery-ocp==7.8.1.0 -- the problem is that OCCT/OCP 7.8 introduced incompatibilities in the API that affect build123d which did not have strict enough version requirements for 0.8.0 and below. This means that build123d will not work correctly.

The workaround:

pip install build123d "cadquery-ocp<7.8"

This problem will be corrected soon in a future release of build123d.

EDIT: also note that python 3.13 is NOT supported on build123d==0.8.0 and older

@jdegenstein jdegenstein changed the title pip install build123d is broken for version 0.8.0 pip install build123d is broken for version 0.8.0 and below Jan 13, 2025
@gumyr gumyr added the bug Something isn't working label Jan 14, 2025
@gumyr gumyr added this to the Gating Release 1.0.0 milestone Jan 14, 2025
@gumyr
Copy link
Owner

gumyr commented Jan 14, 2025

I'm not sure if this is gating or not. Are we going to support older versions of OCP for an extended length of time?

@jdegenstein
Copy link
Collaborator Author

Sorry my point was to say that this needs to be fixed soon. Maybe that tag was not appropriate for this.

@42sol-eu
Copy link
Contributor

I can test updazes on MacOS for intel and arm64 if it helps

@gumyr gumyr added this to the Gating Release 1.0.0 milestone Jan 24, 2025
@contagnas
Copy link

contagnas commented Jan 26, 2025

I had trouble finding this issue in search so adding an error this caused for me:

    out[item.HashCode(HASH_CODE_MAX)] = (
        ^^^^^^^^^^^^^
AttributeError: 'OCP.OCP.TopoDS.TopoDS_Shape' object has no attribute 'HashCode'

(Pinning cadquery-ocp worked, thanks!)

@jdegenstein
Copy link
Collaborator Author

Thank you @contagnas and sorry for the oversight!

jgraichen added a commit to jgraichen/someline that referenced this issue Jan 27, 2025
See gumyr/build123d#866.

New pipeline will avoid that lock file maintenance will break stuff
again, at least if it stops running.
@Rapter35
Copy link

Thank you @contagnas for making it searchable, I encountered the same issue after installing build123d on a new computer.

out[item.HashCode(HASH_CODE_MAX)] = (
        ^^^^^^^^^^^^^
AttributeError: 'OCP.OCP.TopoDS.TopoDS_Shape' object has no attribute 'HashCode'

@jdegenstein the workaround you proposed of pip install build123d "cadquery-ocp<7.8" returns this error for me:

ERROR: Could not find a version that satisfies the requirement cadquery-ocp<7.8 (from versions: 7.8.1.0, 7.8.1.1, 7.8.1.1.post1)
ERROR: No matching distribution found for cadquery-ocp<7.8

Pip is version pip-25.0, in case that helps.

Thank you.

@CePeU
Copy link

CePeU commented Feb 1, 2025

I just installed it with my portable version and it worked/works. For the install pip-24.xx was used. I upgraded to pip 25.0 after the cadquery update.

System is Windows with a seperate portable VSCode and python setup.

Image

@jdegenstein jdegenstein changed the title pip install build123d is broken for version 0.8.0 and below pip install build123d is broken for version 0.8.0 and below (AttributeError: '... TopoDS_Shape' object has no attribute 'HashCode') Feb 2, 2025
@jdegenstein
Copy link
Collaborator Author

jdegenstein commented Feb 2, 2025

@Rapter35 build123d==0.8.0 and lower do NOT support python 3.13 (they only support python 3.9 through 3.12). You can either use older python or newer build123d from github.

@jdegenstein
Copy link
Collaborator Author

FYI, build123d 0.9.0 was released yesterday to PyPI. I plan to close this issue in the next few days as we are not planning to fix the older releases of build123d.

https://github.com/gumyr/build123d/releases/tag/v0.9.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants