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

Representation of null messages #643

Closed
treiher opened this issue Apr 12, 2021 · 2 comments · Fixed by #1191
Closed

Representation of null messages #643

treiher opened this issue Apr 12, 2021 · 2 comments · Fixed by #1191
Assignees
Labels
model Related to model package (e.g., model verification) refactoring small Effort of one person-day or less

Comments

@treiher
Copy link
Collaborator

treiher commented Apr 12, 2021

Null messages are currently represented by an empty structure in AbstractMessage. This leads to special handling in some cases. For example in graph and pyrflx.typevalue:

178         assert isinstance(self.__data, Message)
179 
180         if not self.__data.structure:
181             self.__data.structure = [Link(INITIAL, FINAL)]
639         # structure is empty for NULL messages
640         if field == FINAL or not self._type.structure:
641             return None

Representing a null message by a structure of a single link from INITIAL to FINAL could make these special cases unnecessary.

@treiher treiher added the model Related to model package (e.g., model verification) label Apr 12, 2021
@treiher treiher added this to To do in RecordFlux 0.7 via automation Apr 12, 2021
@senier
Copy link
Member

senier commented Apr 12, 2021

Maybe I misremember that, but I think we had it like that in the past (or considered that option) and there was a reason to have the special handling. Getting rid of that would indeed be good!

@jklmnn
Copy link
Member

jklmnn commented Apr 12, 2021

Maybe I misremember that, but I think we had it like that in the past (or considered that option) and there was a reason to have the special handling. Getting rid of that would indeed be good!

Yes there was a specific reason to do it like this although I can't remember what it was.

@treiher treiher added the small Effort of one person-day or less label Oct 11, 2021
@senier senier removed this from To do in RecordFlux 0.7 Aug 23, 2022
@senier senier added this to To do in RecordFlux Future via automation Aug 23, 2022
@senier senier removed this from Medium in RecordFlux Future Aug 30, 2022
@senier senier added this to To do in RecordFlux 0.7 via automation Aug 30, 2022
@treiher treiher moved this from To do to Implementation in RecordFlux 0.7 Sep 20, 2022
@treiher treiher self-assigned this Sep 20, 2022
treiher added a commit that referenced this issue Sep 20, 2022
treiher added a commit that referenced this issue Sep 20, 2022
@treiher treiher moved this from Implementation to Review in RecordFlux 0.7 Sep 20, 2022
treiher added a commit that referenced this issue Sep 22, 2022
treiher added a commit that referenced this issue Sep 22, 2022
treiher added a commit that referenced this issue Sep 22, 2022
RecordFlux 0.7 automation moved this from Review to Done Sep 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
model Related to model package (e.g., model verification) refactoring small Effort of one person-day or less
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants