Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
exsolvespacer
Posts: 169
Joined: Sat Jan 23, 2021 1:15 pm

Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by exsolvespacer »

I have a body that I designed in Part Design.

I used Draft workbench to:

1) Rotate the Body (array tool).
2) Mirror the Body (array tool).

I then realised I needed to pocket the original Body. I went back to Part Design and clicked Sketch then select the plane, but I get a "Cyclic reference" problem and it will not allow me to create the sketch:
problem.png
problem.png (94.71 KiB) Viewed 1896 times
If I delete all the Array operations, I can then create the Sketch on the plane. What am I doing wrong? It seems like a bug.

Thanks.
lock.FCStd
(38.05 KiB) Downloaded 23 times

Code: Select all

Version: 2022.111.30764 (Git) AppImage
Build type: Release
Branch: LinkDaily
Hash: ef3092bcbca5475eff4eb7ff7933eb3e9bbbe4b9
Python version: 3.9.9
Qt version: 5.12.9
Coin version: 4.0.1
OCC version: 7.5.3
Locale: English/United Kingdom (en_GB)
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by GeneFC »

It is not a bug, it is a feature. :o

Seriously, what are you trying to do? This object is so simple that everything can be done directly in PD. No need to even attempt to use Draft or any other workbench.

There are strict limitations on mixing workbench operations. Stay away from those mixtures unless you are sure they are needed and that they will work.

Gene
User avatar
adrianinsaval
Veteran
Posts: 5544
Joined: Thu Apr 05, 2018 5:15 pm

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by adrianinsaval »

No issue adding a new sketch in master, I think realthunder prefers bug reports on github. I don't think you'll get much help here unless you ping him.
On the other hand, there's really no need to use Draft here
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by chrisb »

Gene is of course right that this should be modeled in PartDesign. Besides that it seems to be an issue in the branch. There is no such issue in master.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
heron
Posts: 307
Joined: Mon Apr 20, 2020 5:32 pm

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by heron »

If you re-edit the attachment of a sketch and try to give it a reference to a later object created from that sketch, you are creating a cyclic reference error. I think that is the normal behavior also in the master branch.
Regards.
exsolvespacer
Posts: 169
Joined: Sat Jan 23, 2021 1:15 pm

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by exsolvespacer »

Thanks for the replies.

I didn't realise that I wasn't meant to mix workbenches.

How can I rotate the "quarter circle" part?

I was trying to be clever by making the simplest part possible and then using mirror and rotation operations to arrange 4 of those original simple parts into the overall part that I needed.

Let's say I just make the semicircular part. I now need to mirror it.

How can I mirror a body in part design?
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by chrisb »

exsolvespacer wrote: Thu Jan 13, 2022 10:59 pm I didn't realise that I wasn't meant to mix workbenches.

How can I rotate the "quarter circle" part?
You can indeed mix the workbenches, and you did it almost right - by applying the Part functions to the whole body. (To use this mixture is very sensible for very complex bodies, this one could better have been made completely in PartDesign.)

I don't know how you created the cyclic dependency the error you made was that you created the mirror outside of part.

And if you move the mirror into the part, you see another flaw: You will have the Part with only one object inside which makes the Part container useless. You should delete it (but of course not the contents). The tree should look like this:
SnipScreenshot-3d0ab6.png
SnipScreenshot-3d0ab6.png (28.64 KiB) Viewed 1684 times
Attachments
lock_part_mirror_cb.FCStd
(21.91 KiB) Downloaded 24 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by chrisb »

To do it completely in PartDesign I have introduced a DatumPlane as mirror plane and made a MultiTransform with two mirrors:
SnipScreenshot-522633.png
SnipScreenshot-522633.png (34.12 KiB) Viewed 1675 times
Attachments
lock_PartDesign_mirror_cb.FCStd
(26.22 KiB) Downloaded 18 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
exsolvespacer
Posts: 169
Joined: Sat Jan 23, 2021 1:15 pm

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by exsolvespacer »

chrisb wrote: Thu Jan 13, 2022 11:12 pm You can indeed mix the workbenches, and you did it almost right - by applying the Part functions to the whole body. (To use this mixture is very sensible for very complex bodies, this one could better have been made completely in PartDesign.)

I don't know how you created the cyclic dependency the error you made was that you created the mirror outside of part.

And if you move the mirror into the part, you see another flaw: You will have the Part with only one object inside which makes the Part container useless. You should delete it (but of course not the contents). The tree should look like this:SnipScreenshot-3d0ab6.png
Thanks. This looks neater, however I still cannot pick a plane to create a sketch within "Body". I still get the circular errors.

The multi-transform thing is new to me but does just what I want. Thanks.
chrisb
Veteran
Posts: 54150
Joined: Tue Mar 17, 2015 9:14 am

Re: Unable to create new sketch in body that has had array tool used on it (cyclic reference)

Post by chrisb »

exsolvespacer wrote: Fri Jan 14, 2022 1:58 pm however I still cannot pick a plane to create a sketch within "Body". I still get the circular errors.
I did it in master, and I still guess that this is an issue in your branch.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Post Reply