-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fedsd fix self_id #271
Fedsd fix self_id #271
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I looked at this, but I have to admit that I neither understand the original comment/code nor the change. In the new comment, it says that "'self_id'
should not be -1
," but the former is a string (which happens to be used as a key) and the latter is a number, so they can never be equal... I'm also unclear on what should means to convey. Are you trying to describe an invariant? I don't see an actual check where anything gets compared against -1
, either, so I'm a bit confused... The for loop appears to assign to id
the first 'Receiving'
event that it can find. Could you explain why it does that?
Sure! In order to identify the interacting components (federates and RTI), The event The fix checks that we are reading the A counter-example was found, that's why this fix correctly reads the actual |
OK, thanks, that clear it up! I would then make a change a long these lines:
Does that make sense? |
A minor tweak of the tweak:
Ok? |
👍 |
This PR fixes a bug that @jackykwok2024 reported when using
fedsd
utility withPython
target.Previously, we relied on the last event of a trace (after processing) not being about advancing time. A federate will send a resignation message after the last time advance. This behavior is valid in the C target, but it is not the case in the Python target.
In this PR,
fedsd
retrieves the correctself_id
of a federate.