Seg fault if ksolve is deleted before stoich
hrani opened this issue · comments
Seg fault if ksolve is removed before stoich
import moose
moose.loadModel('~/acc27.g','/acc27',"gsl")
compts = moose.wildcardFind('/acc27/##[ISA=ChemCompt]')
for compt in compts:
if moose.exists(compt.path+'/stoich'):
st = moose.element(compt.path+'/stoich')
st_ksolve = st.ksolve
moose.delete(st)
#print st_ksolve.path
if moose.exists((st_ksolve).path):
moose.delete(st_ksolve)
print " stoich is removed first and then ksolve, works fine\n"
print " If ksolve is removed first and then stoich then gives seg fault\n"
moose.loadModel('~/acc27.g','/acc27_1',"gsl")
compts = moose.wildcardFind('/acc27_1/##[ISA=ChemCompt]')
for compt in compts:
if moose.exists(compt.path+'/stoich'):
st = moose.element(compt.path+'/stoich')
#print " stoich ksolve ",st.ksolve.path
if moose.exists((st.ksolve).path):
moose.delete(st.ksolve)
moose.delete(st)
This is moose-core issue rather than moose-gui a ticket is created at
BhallaLab/moose-core#69