issue #4100
So, I tried to reproduce it. I did about two times, but I failed to make it reliably. I have however full steps that lead to a similar problem but without error message.
1. open attached file.
2. Go to Draft, activate Point tool.
-> task appears
3. In task, tick "Continue mode"
4. Draw some points by clicking the screen
5. Finish the tool by clicking "Close" on task
-> the last created point remains selected. Let it remain selected, it's important.
6. activate BezCurve tool
7. Click any Point object in 3d view
-> task closes. BezCurve object appears in tree view, but it has Part Cube icon to it. Also, an extra Point object appears. But no error messages in report view.
After that, attempting to use Draft, all sorts of weirdness begins, such as drawing a Bezier curve when Point tool is active, or drawing the curve even without any tool being active.
All snap modes are ON at step 7.
OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.17803 (Git)
Build type: Release
Branch: master
Hash: 89961a33d46063a43e9fb5b0308ca95d559eca94
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Russian/Russia (ru_RU)
Ticket #4100 - Draft "crash" when drawing bezier curve
Forum rules
and Helpful information
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!
Also, be nice to others! Read the FreeCAD code of conduct!
Re: Ticket 4100 Draft "crash" when drawing bezier curve
After this step, I get this message:
Code: Select all
Pick first point
Traceback (most recent call last):
File "/opt/freecad-build-vocx/Mod/Draft/DraftGui.py", line 151, in doTasks
f()
TypeError: _removeSwitch() missing 1 required positional argument: 'switch'
('[Draft.todo.tasks] Unexpected error:', <class 'TypeError'>, 'in ', <bound method Tracker._removeSwitch of <DraftTrackers.PlaneTracker object at 0x7f8050e84518>>, '(', None, ')')<class 'RuntimeError'>
Now if I keep trying to draw with the Bezier tool, I get the error message in red:After that, attempting to use Draft, all sorts of weirdness begins, such as drawing a Bezier curve when Point tool is active, or drawing the curve even without any tool being active.
Code: Select all
Traceback (most recent call last):
File "/opt/freecad-build-vocx/Mod/Draft/DraftTools.py", line 925, in action
self.ui.redraw()
File "/opt/freecad-build-vocx/Mod/Draft/DraftGui.py", line 979, in redraw
self.checkLocal()
File "/opt/freecad-build-vocx/Mod/Draft/DraftGui.py", line 1366, in checkLocal
self.labelx.setText(translate("draft", "Global X"))
RuntimeError: Internal C++ object (PySide2.QtWidgets.QLabel) already deleted.
Code: Select all
OS: Ubuntu 18.04.3 LTS (ubuntu:GNOME/ubuntu)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.17959 +53 (Git)
Build type: Unknown
Branch: DraftFillet_improved
Hash: aa670539775d77bca3d45ff891b297ade8849298
Python version: 3.6.8
Qt version: 5.9.5
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
The error messages seem to be during establishing the tracker of the spline, or something around that DraftTrackers.PlaneTracker.
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
Re: Ticket #4100 - Draft "crash" when drawing bezier curve
Could it be something I messed up when adding possibility to draw a bezier curve with fixed degree?... I'm out of home till next week, I'll check this asap...
follow my experiments on BIM modelling for architecture design
- DeepSOIC
- Veteran
- Posts: 7896
- Joined: Fri Aug 29, 2014 12:45 am
- Location: used to be Saint-Petersburg, Russia
Re: Ticket #4100 - Draft "crash" when drawing bezier curve
Unlikely, as in the Russian thread (https://forum.freecadweb.org/viewtopic.php?f=29&t=38955), cynabr reports that the bug is even in v0.16.
Re: Ticket #4100 - Draft "crash" when drawing bezier curve
Uff .. I was scared it was my fault .. I'll check it anyway asap
follow my experiments on BIM modelling for architecture design
Re: Ticket #4100 - Draft "crash" when drawing bezier curve
If this is true, then it's possibly a hard to trigger bug, which is why it hasn't been addressed in a long time. I personally think that it's weird to trigger it in the way described by the first post. The spline can be attached directly to the grid, so there is no need to create the points in the first place.
The bug is probably somewhere in the Spline code that handles the scene view, and the creation or destruction of the trackers. So we'd need to take a look that these functions are triggered in the right order, and that they don't try to use already destroyed objects.
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
Re: Ticket #4100 - Draft "crash" when drawing bezier curve
Perhaps this can be related to a problem I spotted with the Draft Point when using continue mode:
if I draw several point in continue mode, and click close, the command does not finish, but let me add another point.
So if I click close and select another tool, i produce an error. This happens always in:
if I draw several point in continue mode, and click close, the command does not finish, but let me add another point.
So if I click close and select another tool, i produce an error. This happens always in:
Code: Select all
OS: Windows 7 SP 1 (6.1)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.21349 (Git)
Build type: Release
Branch: master
Hash: 28222fe066b60ae5c99dce4e5b022d270cad250f
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: Italian/Italy (it_IT)
follow my experiments on BIM modelling for architecture design