View Issue Details

IDProjectCategoryView StatusLast Update
0001287FreeCADBugpublic2013-11-04 22:53
Reporterniklasderkueste Assigned Toyorik  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Version0.13 
Fixed in Version0.14 
Summary0001287: Loosing Snap when Object is getting more complex.
DescriptionHi Yorik! (This is my first report ever, so be kind)

Windows Vista 64, Windows 7
Version: 0.13.1828
Python version: 2.6.2
Python Command Line says 3.3.2
Qt version: 4.5.2
Coin version: 3.1.0
SoQt version: 1.4.1
OCC version: 6.3.0


<-Here I explain my Workflow for the case I'm doing something wrong.
<
<It is like this: Every part I work on is mainly something like a box, and I <found out that is very comfortable to layout the projections for the sketches <in 2d cad around (0,0),

before I start freecad. So I dont have to use any <constraints, the sketches just jump in 3d to the right place.
<Then I turn each 2d part which has the same depth into a block, projecting as <one sketch on the main volume and cutting them out (most efficient for me), <champfering and filleting

when the part is done. After that, I only work with <copied solids and try to fuse as many parts together as possible with the <openscad workbench. I'm only doing so because I want to

move as less objects <as possible in 3d space and the lines are hidden when I use the project 2d <button.

The Main Point:

Draw a line, Move/Rotate, Dimensoning a Part (all Draft Tools witch depend on coordinates) are not working anymore when i finish some of the parts.
The funny thing is that Preselect still perfectly shows Vertex Positions in Yellow.
(I use it for 'Incremential' movement which is the only possible placement method for me right now, without snapping)

When I hover above some parts the preselection is fine (yellow lines,planes etc) but the big black points for the fine draft snaps are missing. When the preselection grabs I got these

errors (all the same):

------------------------------------------------------------
Active document is Chair (at 0A43ED38)
Pick first point:
<type 'exceptions.TypeError'>
Traceback (most recent call last):
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 483, in action
    self.point,ctrlPoint,info = getPoint(self,arg)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 144, in getPoint
    point = FreeCADGui.Snapper.snap(args["Position"],lastpoint=last,active=amod,constrain=cmod)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 191, in snap
    point,eline = self.snapToExtensions(point,lastpoint,constrain,eline)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 386, in snapToExtensions
    if isinstance(e.Curve,Part.Line):
TypeError: undefined curve type
<type 'exceptions.TypeError'>
Traceback (most recent call last):
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 483, in action
    self.point,ctrlPoint,info = getPoint(self,arg)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 144, in getPoint
    point = FreeCADGui.Snapper.snap(args["Position"],lastpoint=last,active=amod,constrain=cmod)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 191, in snap
    point,eline = self.snapToExtensions(point,lastpoint,constrain,eline)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 386, in snapToExtensions
    if isinstance(e.Curve,Part.Line):
TypeError: undefined curve type
<type 'exceptions.TypeError'>
Traceback (most recent call last):
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 483, in action
    self.point,ctrlPoint,info = getPoint(self,arg)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftTools.py", line 144, in getPoint
    point = FreeCADGui.Snapper.snap(args["Position"],lastpoint=last,active=amod,constrain=cmod)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 191, in snap
    point,eline = self.snapToExtensions(point,lastpoint,constrain,eline)
  File "C:\Program Files (x86)\FreeCAD0.13\Mod\Draft\DraftSnap.py", line 386, in snapToExtensions
    if isinstance(e.Curve,Part.Line):
TypeError: undefined curve type
<type 'exceptions.TypeError'>
---------------------------------------------------------------
After that I can not draw anything by clicking in the main view. No Snap at all. Some computers I can revive draft snap by open a new document, at mine by restarting freecad. But as

soon I hover even small and not so complex objects with this error its gone. While really using it for for work I found out, it is the best to turn off 'Always snap to objects' not to

loose snap accidentally, and just use snap when i need it.

Does somebody have a good idea?
Additional InformationMaybe 'Jürgen Kilb' (earlyer post) had a similar problem while moving the spheres.
TagsNo tags attached.
FreeCAD Information

Activities

yorik

2013-10-25 20:22

administrator   ~0003807

Hm it looks like some of your objects contain edges of an unknown type... I have never seen this before. Could you attach one of those objects here so I can have a look?

2013-10-26 17:11

 

nosnap.FCStd (Attachment missing)

niklasderkueste

2013-10-26 17:13

reporter   ~0003814

Update: I finally managed to upload an example Object.

yorik

2013-10-27 15:58

administrator   ~0003818

Okay I see... Indeed there is some weird edge there, that screws the snap system (and consequently all draft commands after it). I'll try to fix this ASAP. In the meantime, FYI, if you press escape when the problem appears, it resets the snapping system, and things should continue to work normally after.

niklasderkueste

2013-10-27 19:33

reporter   ~0003819

Last edited: 2013-10-27 19:36

At the Computers I tested on, Escape does not work, I have to reopen the document or open a new one. It still works to type in the coordinates in the draft bar after the errors. maybe there is a command for reset I could try. Anyway right now I use placement tool as workaround, and make the drafts in another document. it works quite well.

Thank you for taking a look onto this.
Niklas

yorik

2013-10-27 22:27

administrator   ~0003820

Ok this is now fixed in the current source code, you might need to wait a bit until someone builds a new windows package, though...

Fixed with commit 7249ee

Related Changesets

FreeCAD: master 7249ee4b

2013-10-27 21:26:10

Yorik van Havre

Details Diff
0001287: Bug in draft snapping Affected Issues
0001287
mod - src/Mod/Draft/DraftSnap.py Diff File

Issue History

Date Modified Username Field Change
2013-10-25 19:09 niklasderkueste New Issue
2013-10-25 20:22 yorik Note Added: 0003807
2013-10-25 20:23 yorik Status new => assigned
2013-10-25 20:23 yorik Assigned To => yorik
2013-10-26 17:11 niklasderkueste File Added: nosnap.FCStd
2013-10-26 17:13 niklasderkueste Note Added: 0003814
2013-10-27 15:58 yorik Note Added: 0003818
2013-10-27 19:33 niklasderkueste Note Added: 0003819
2013-10-27 19:34 niklasderkueste Note Edited: 0003819
2013-10-27 19:36 niklasderkueste Note Edited: 0003819
2013-10-27 22:27 yorik Note Added: 0003820
2013-10-27 22:27 yorik Status assigned => closed
2013-10-27 22:27 yorik Resolution open => fixed
2013-10-27 22:27 yorik Fixed in Version => 0.14
2013-11-04 22:53 yorik Changeset attached => FreeCAD Master master 7249ee4b