CadQuery Comes of Age
hackaday.com
hackaday.com
See here for the discussion.
The developers don't seem to be receptive. But fortunately a nix flake exists: https://github.com/marcus7070/cq-flake
Takes ages to compile thought so I advice you to either be patient or add the cache.
I already have python installed. Why do I need anaconda? What is anaconda? "A data science toolkit" (from their website) ? Why do I need that? Why can't I just "pip install cadquery" and expect it to work?
It turns out conda is an alternative package manager for python, and cadquery is only distributed via conda, not pip. I'm surprised this basic bit of information is (still) not explained in the docs.
The issue you created finally explained _why_ to me, so thanks for that :)
The problem is that cadquery depends on OpenCascade Technology (OCCT), a 3D geometry library. A full build is ~1.5GB, and it is the reason why the download for CadQuery is so big. PyPI is not meant for such large packages, and currently has no mechanism to allow for out of bounds binary downloads.
That said, if you need to mix various modules on conda it can really be a challenge to find a conflict-free configuration, I agree.
They are pretty hostile to pypi devs with regards to the fact they were asking pypi to distribute their 1Gb+ python packages, rather than trying to modularize their packages to make it easier to distribute.
https://github.com/CadQuery/cadquery/issues/153#issuecomment...
NLTK has a method so the library can be installed through pypi and the data can be downloaded through the following method:
import ntlk
ntkl.download()
So given what I've been reading about cadquery the less and less I want to deal with their software.Cadquery works fine for me in its own separate miniconda environment. The full anaconda is not needed. If dependency resolution fails or is slow, I suggest using mamba for the cadquery / cq-editor install commands – way faster and more reliable.
I'm sure you know this if you use CadQuery, just saying it for the rest of the crowd.
"Look how easy it is. All you need to do is to do is to install miniconda, and wait for it to download 1GB of software. Hope it doesn't break any installed pythons or your pythonpath or any existing packages!"
I don't know why Conda / CadQuery dependencies are so big, but I have more than enough space for them.
Python is far from my favorite language, both in terms of coding and setting it up, but we're not exactly swimming in open source programmable[1] CAD solutions. There's OpenSCAD which is more limited, there's JSCAD that I haven't tried, and... that's pretty much it? CadQuery seems to be the most mature option from my limited experience, despite the annoyance with conda.
[1] I'm aware that some visual CAD apps like FreeCAD have some scripting / plugin support, but it's not the same when this coding isn't the primary building interface, and those apps all have their own (significant) issues anyway.
Neither am I, nor do I want to find out if it does, given their poor track record of messing with PATH and pythons and stuff.
Exactly the first reason why I don't consider cadquery a viable tool (not the only one): conda is a monstrosity (even miniconda) that will irrevocably maim your system if you're crazy enough to install it.
Another reason is this: selecting a subcomponent in a complex hierarchical model is basically a nightmare:
I understand that other modes of using CadQuery require 'conda, but the basic built-in editor experience is self contained. Or am I misunderstanding something?
That said, for me the miniconda setup was annoying but not too hard. Wouldn't say it's the worst part.
Learning the concepts and APIs with no prior 3D experience is a lot harder. Results are worth it though.
something with contexts would be nice, maybe?
with cq.Workplane("XY").box(h,w,t) as plate: plate.faces(">Z").workplane().hole(diameter) show_object(plate)
there's got to be some compromise between the explicitness of cadquery, and the implictness of openscad.
You can always use intermediate variables if you want to.
Because it's python, you can always use parentheses to split long lines neatly.
I don't know why the article makes it sound like cadquery is superior in every way possible. Sure BREP is a lot more powerful than CSG, but with extra power comes extra learning curve. If all you ever design is 3d prints for reprap (and I'd guesstimate 95% of hackaday audience falls into that category) cadquery may be an overkill
you've completely wasted both our times.
Most cadquery examples are hard to follow due to context implicitness. They are basically write only.