Closed max-talanov closed 1 year ago
@max-talanov are you referring to the elif
block in the update
block?
# sending spikes: crossing 0 mV, pseudo-refractoriness and local maximum...
if n_r > 0: # is refractory?
n_r -= 1
elif V_m > 0 mV and U_old > V_m: # threshold && maximum
n_r = RefractoryCounts
emit_spike()
Please provide the example code where elif
doesn't work for you.
I have created the file to reproduce an error please see line 359: https://github.com/max-talanov/bypass/blob/main/nestML/muscle/nestmlmodule/hh_moto_5ht_muscle.nestml#L359
@max-talanov This was a typo in the function name and apparently, none of our tests caught it. Thank you for pointing this out. I have fixed this also in #950.
@pnbabu thank you so much!
Fixed in #950.
Dear developers. I'm trying to extend nest with muscle model. Unfortunately I have hit the problem that if i use elif nestml language construct the compilation process crashes with the following error message: File "/home/max/.local/lib/python3.10/site-packages/NESTML-5.3.0.post0.dev0-py3.10.egg/pynestml/cocos/co_co_user_defined_function_correctly_defined.py", line 67, in check_co_co cls.check_return_recursively(symbol.get_return_type(), File "/home/max/.local/lib/python3.10/site-packages/NESTML-5.3.0.post0.dev0-py3.10.egg/pynestml/cocos/co_co_user_defined_function_correctly_defined.py", line 142, in check_return_recursively cls.__check_return_recursively(type_symbol, else_ifs.get_block().get_stmt(), ret_defined) AttributeError: 'ASTBlock' object has no attribute 'get_stmt'. Did you mean: 'get_stmts'?
If I use nested ifs then compilation works fine. Thank you so much in advance.