You are correct, changing the order of the unions fixes the issue.
The other strange discrepancy I ran into is similarly fixable by just messing around with the code a little. There is no immediacy as I just ran into this while working through a project. I got past it and once I cleaned up and finalize it is not a problem. It was just strange and I don't know if it is a bug or just my messy beginner code. Here is what I ran into:
Python:
import cadquery as cq
base = (cq.Workplane("XY").circle(37).extrude(48))
hole = (cq.Workplane("XY").circle(29.5).extrude(48))
upper = (base.faces(">Z").circle(37).extrude(42, combine=False))
side = (cq.Workplane("XY").workplane(offset=90).moveTo(33,0).rect(-66,-100, centered=False).extrude(-50))
upperside = upper.union(side)
posthole = (cq.Workplane("XY").moveTo(0,-25).workplane(offset=90).rect(38,38).extrude(-35, combine=False))
final = base.union(upperside).cut(posthole).cut(hole)
show_object(final, options={"rgba":(204, 204, 204, 0.0)})
If I run this is FreeCAD, it works. If I run it in cq-editor I get an error "Standard_NullObject: BRep_Tool:: TopoDS_Vertex hasn't gp_Pnt". It looks like the error occurs at line 15 (final = ...). The strange bit is that this appeared when I made a change to line 9. I had started with a value for the moveTo of 37 (same as the base circle) and this value does not produce an error. In fact, as long as I make the moveTo value larger then the base circle, there is no error. If I make it smaller then the base circle, I get the error.
As I said, I've gotten long past this with cleaner code, this popped up while I was designing a part. It just seemed strange.
Thanks for everyone's work on CadQuery. It is by far the program I like best to design parts to print.