Out of range error with Python MeshFunction iterator

Bug #973906 reported by Garth Wells
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
DOLFIN
Fix Committed
Low
Johan Hake

Bug Description

The below code leads to DOLFIN throwing an error:

from dolfin import *
mesh = UnitSquare(2, 2)
mf = CellFunction("uint", mesh, 0)
for f in mf:
    print f

Johannes Ring (johannr)
Changed in dolfin:
status: New → Confirmed
Revision history for this message
Johan Hake (johan-hake) wrote :

MeshFunction.__getitem__ raised a RuntimeError (from cpp library) instead of an IndexError. It now raises the correct error and a MeshFunction is now iterable

Changed in dolfin:
importance: Undecided → Low
assignee: nobody → Johan Hake (johan-hake)
milestone: none → trunk
status: Confirmed → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.