← Back to team overview

dolfin team mailing list archive

Re: [Bug 713081] [NEW] mesh-entities-broken

 

Anders, can you look over the initialization of the Mesh object, and double 
check that everything is correctly intialized and destroyed. 

I have a funny feeling that this error was introduced because some lowlevel 
hard to debug error.

The typemaps are OK, and the error goes away if I introduce a std::cout 
withing the typemap, indicating memory corruption.

Johan


On Friday February 4 2011 08:27:57 Johan Hake wrote:
> This looks like a Heisenbug to me!
> 
> When I put a print statement into the typemap it works, when I remove the
> print statement it appears...
> 
> With print statement ("size connectivity X"):
> 
>   In [4]: print cell.num_entities(0), len(cell.entities(0))
>   3size connectivity 3
>   3
> 
> without:
> 
>   In [4]: print cell.num_entities(0), len(cell.entities(0))
>   3 0
> 
> Puzzled...
> 
> Johan
> 
> On Friday February 4 2011 05:05:23 Anders Logg wrote:
> > Public bug reported:
> > 
> > The following code prints 3, 0 but should print 3, 3:
> > 
> > from dolfin import *
> > 
> > mesh = UnitSquare(2, 2)
> > cell = Cell(mesh, 0)
> > 
> > print cell.num_entities(0), len(cell.entities(0))
> > 
> > Perhaps a broken typemap for uint*?
> > 
> > ** Affects: dolfin
> > 
> >      Importance: High
> >      
> >          Status: Confirmed
> > 
> > ** Changed in: dolfin
> > 
> >        Status: New => Confirmed
> > 
> > ** Changed in: dolfin
> > 
> >    Importance: Undecided => High
> > 
> > ** Changed in: dolfin
> > 
> >     Milestone: None => 0.9.10

-- 
You received this bug notification because you are a member of DOLFIN
Team, which is subscribed to DOLFIN.
https://bugs.launchpad.net/bugs/713081

Title:
  mesh-entities-broken

Status in DOLFIN:
  Confirmed

Bug description:
  The following code prints 3, 0 but should print 3, 3:

  from dolfin import *

  mesh = UnitSquare(2, 2)
  cell = Cell(mesh, 0)

  print cell.num_entities(0), len(cell.entities(0))

  Perhaps a broken typemap for uint*?





Follow ups

References