Ticket #3558 - Arch Windows - Problem with Draft to Sketch

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Ticket #3558 - Arch Windows - Problem with Draft to Sketch

Post by Wilson »

issue #3558 https://www.freecadweb.org/tracker/view.php?id=3558

I'm halfway through the Arch Tutorial and I'm having issues, creating the curtain walls. I did a small part of it as explained in the tutorial and it was fine, using several rectangles and then converting these draft objects to a sketch with the Draft To Sketch tool. Now I'm trying to do the same with a bigger section of the curtain wall and I can't. The sketch seems to be empty every time I repeat this process. To model these objects I'm using the dxf reference, as in the tutorial. I tried making a random window without aside and it worked fine. Unfortunately, every time I go back and draw wires or rectangles onto the dxf the same problem happens again, the sketch is empty and there is no window as a result. Because I modeled the whole thing so far using the dxf reference, it would be better to do the windows the same way. Apparently I managed to do it at first, but now I'm stuck. I have redrawn the whole thing several times, with wires, wires and rectangles, in small sections... and no success.

Attached you'll find a copy of the file and a printscreen as well.

OS: Windows 7
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.13528 (Git)
Build type: Release
Branch: releases/FreeCAD-0-17
Hash: 5c3f7bf8ec51e2c7187789f7edba71a7aa82a88b
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
Attachments
printscreen.jpg
printscreen.jpg (441.26 KiB) Viewed 2023 times
Artigas v2.3.FCStd
(545.31 KiB) Downloaded 35 times
Last edited by Wilson on Tue Aug 14, 2018 6:57 pm, edited 2 times in total.
paullee
Veteran
Posts: 5120
Joined: Wed May 04, 2016 3:58 pm

Re: Arch WIndows - Problem with Draft to Sketch

Post by paullee »

Out of curiosity I try... I do not know the reason, but following workflow seems works :-

Maybe Yorik or other can explain the desirable workflow :)
  1. select the Dwire you want
  2. Draft Upgrade (the Up Arrow) it - this turn it into a Face object
  3. Now, turn the face into a sketch with Draft to Sketch, and it works :!: :?:
Screenshot from 2018-08-12 23-30-09.png
Screenshot from 2018-08-12 23-30-09.png (205.85 KiB) Viewed 1996 times
Screenshot from 2018-08-12 23-29-57.png
Screenshot from 2018-08-12 23-29-57.png (178.97 KiB) Viewed 1996 times
Attachments
Artigas v2.3_r.FCStd
(689.76 KiB) Downloaded 33 times
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Re: Arch WIndows - Problem with Draft to Sketch

Post by Wilson »

Thanks paullee. I think I may have a bug, I tried your workflow and I keep getting the same problem. Just out of curiosity, you're using FreeCAD 0.18_dev? I have the latest version of the 0.17 and maybe that's why you can do the sketch and I can't.
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Re: Arch WIndows - Problem with Draft to Sketch

Post by Wilson »

I tried to repeat the process with another computer and some draft objects, after applying the draft2sketch tool, are converted to sketch with no problems, but with others, the result is the same as before, a new sketch completely empty. I tried this with both the latest stable version (0.17.13528) as well with the 0.18 development version. The result is the same, some draft objects are converted to sketch with no problem, others aren't. Also, it seems to be random, I can't find a pattern to in order to understand why some objects work fine and others don't. I believe it's a bug.
paullee
Veteran
Posts: 5120
Joined: Wed May 04, 2016 3:58 pm

Re: Arch WIndows - Problem with Draft to Sketch

Post by paullee »

Hi, I am using FreeCAD-13521.glibc2.17-x86_64.AppImage
(Not aware there is already 15328 :oops: )

I try some more DWire and indeed more are not able to be upgraded.

Convert DWire to Sketch return following errors in Report View Window:-

Code: Select all

('[Draft.todo.commit] Unexpected error:', <class 'Base.FreeCADError'>, 'in ', <built-in method closeDialog of tuple object at 0x7fe297fe5320>, '(', None, ')')
Should have bugs, check what you have in your Report View and report here.

Probably change your Thread Title to something like 'Bug Report', and ping Yorik? I think. Better still report in the bugzilla for FreeCAD.
paullee
Veteran
Posts: 5120
Joined: Wed May 04, 2016 3:58 pm

Re: Arch WIndows - Problem with Draft to Sketch

Post by paullee »

BTW, there is discussion a top of Help forum on:-
https://forum.freecadweb.org/viewtopic.php?f=3&t=5236 Bug submission guidelines

Also a link at the top of the page link to the Mantis bug tracker.
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Re: Bug Report - Arch Windows - Problem with Draft to Sketch

Post by Wilson »

Thanks paullee!

This is what I get in the Report View after selecting all the wires and applying the Draft2Sketch.

Code: Select all

('[Draft.todo.commit] Unexpected error:', <class 'Base.FreeCADError'>, 'in ', <built-in method closeDialog of tuple object at 0x0000021F1EC54188>, '(', None, ')')
I already did a report on the Mantis bug tracker. I'm not sure if I did it accordingly to procedure, I'm still getting the hang of this, both on the software and the forum. Anyway, it was with the best of intentions.

Btw, I downloaded the file available with the Arch Tutorial, and all the curtain walls (window objects) are visible in the Combo View but invisible in the model. I select the windows, press space bar several times and nothing happens. Just by opening the file, it returns a very extensive error report.

I didn't know you can ping someone here. How do you do that?

Just in case, here is the FreeCAD version info that I'm using for this test:

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.13528 (Git)
Build type: Release
Branch: releases/FreeCAD-0-17
Hash: 5c3f7bf8ec51e2c7187789f7edba71a7aa82a88b
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
Attachments
printscreen.jpeg
printscreen.jpeg (273.19 KiB) Viewed 1924 times
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Bug Report - Arch Windows - Problem with Draft to Sketch

Post by Kunda1 »

Wilson wrote: Tue Aug 14, 2018 6:13 pm I didn't know you can ping someone here. How do you do that?
The markup looks like this:

Code: Select all

[quote=Wilson]ping[/quote]
The result looks like this:
Wilson wrote:ping
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Re: Ticket #3558 - Arch Windows - Problem with Draft to Sketch

Post by Wilson »

Kunda1 wrote: Tue Aug 14, 2018 7:12 pm The result looks like this:
Wilson wrote:
ping
Thanks Kunda1.

About the problem with the windows, I don't know if it helps so solve it, but it seems that the draft2sketch tool doesn't work properly if the drawings are something else than rectangles. I mean, you can have two polygons with irregular angles and it may work fine, but if you have a more complex shape, say a curtain wall like in the tutorial, with several different angles in its wires/polygons, it will bug. At least it's the only pattern I think I found.

Anyway, I believe I've reached a solution to work around this problem for now. I'll share it in the next few days, after I test it a little bit more, with some images to illustrate the process. In any case, it doesn't feel like a proper solution, but a temporary fix for this problem.
User avatar
Wilson
Posts: 28
Joined: Fri Jul 13, 2018 6:50 pm
Location: Portugal
Contact:

Re: Ticket #3558 - Arch Windows - Problem with Draft to Sketch

Post by Wilson »

Ok, so here are my findings regarding these windows situation when doing the Arch Tutorial. Like I said before, it seems that the draft2sketch tool doesn't work properly if the drawings are a bit more complex, with wires/polygons of irregular shapes and angles. I don't have any knowledge of Python, so, unfortunately, at this moment I can't help much when it comes to fixing this bug that I believe I found. In any case, a workaround that I came was this:

1 - Draw your window using the Draft_Wire or the Draft_Rectangle
2 - Select all objects and press Draft_Draft2Sketch
3 - Select Sketch and convert to Arch_Window
4 - Enter in Edit Mode and complete sketch with Sketcher_Polyline. Don't worry about snapping at this point.
5 - Click the Sketcher_External and select the wires you've drawn in step 1 and that weren't converted with the Draft2Sketch
6 - Select Constraint_PointOnPoint, Constraint_Vertical and Constraint_Horizontal to make your polygons match the wires.
7 - Done. Now finish your window like it's described in the Arch Tutorial and go have a snack.

If someone has a better workaround, please share because this took me quite some time. With the bug fixed, it will all be easier. I would love to contribute with some bug fixing, but like I said, my knowledge of Python is zero. In any case, if someone could point some tips on how to start getting the hang of it and realistically tell me if it's possible to learn it somehow fast and start contributing, I'll deeply appreciate it. Of course, I know these things take time and I'm still getting the hang on FreeCAD, but it doesn't hurt to ask.
01.jpg
01.jpg (211.08 KiB) Viewed 1849 times
02.jpg
02.jpg (201.28 KiB) Viewed 1849 times
03.jpg
03.jpg (218.59 KiB) Viewed 1849 times
04.jpg
04.jpg (219.39 KiB) Viewed 1849 times
05.jpg
05.jpg (289.37 KiB) Viewed 1849 times
Post Reply