Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix recreation of stepper in workchain 'if' logical block #904

Conversation

sphuber
Copy link
Contributor

@sphuber sphuber commented Nov 9, 2017

There was a mistake in the logic of the 'if' block of workchains when
loading. A position varaiable was being used to keep track of how many
times that conditional block was ticked. This was being upped each
time but also being used to determine which of possible conditional
branches the condition was at e.g.:

if(...)( <-- pos 0

) elif(...) <-- pos 1

) else(

)

Long story short, when the condition was reloaded from a saved state
it was possible that pos was larger than the number of conditions
(usual just one if there's only an if) and it couldn't resume
from where it was when it was saved.

There was a mistake in the logic of the 'if' block of workchains when
loading.  A position varaiable was being used to keep track of how many
times that conditional block was ticked.  This was being upped each
time but also being used to determine which of possible conditional
branches the condition was at e.g.:

if(...)( <-- pos 0

) elif(...) <-- pos 1

) else(

)

Long story short, when the condition was reloaded from a saved state
it was possible that pos was larger than the number of conditions
(usual just one if there's only an if) and it couldn't resume
from where it was when it was saved.
Copy link

@nmounet nmounet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It cannot be worse than before ;-)

@nmounet nmounet merged commit 666bce8 into aiidateam:release_v0.10.0rc3 Nov 9, 2017
@sphuber sphuber deleted the fix_902_incorrect_stepper_recreation_if_construct branch November 9, 2017 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants