Fix crash in _check_table_difference() when table hashes aren't equal - #4823
Open
gizmoguy wants to merge 3 commits into
Open
Fix crash in _check_table_difference() when table hashes aren't equal#4823gizmoguy wants to merge 3 commits into
gizmoguy wants to merge 3 commits into
Conversation
gizmoguy
marked this pull request as draft
July 2, 2026 02:16
gizmoguy
force-pushed
the
fix-check-table-difference
branch
5 times, most recently
from
July 8, 2026 02:04
889a02f to
6b0602e
Compare
gizmoguy
marked this pull request as ready for review
July 8, 2026 02:27
gizmoguy
force-pushed
the
fix-check-table-difference
branch
from
July 8, 2026 02:32
6b0602e to
d36e58b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes this crash in
_check_table_difference():Also as it turns out, hashing of FakeOFTable objects was broken which meant that
_check_table_difference()would not always detect a difference between two different table states. The hash was created based on a frozenset of a string:return hash(frozenset(str(self.tables)))This effectively just counted unique characters in the string representation of a table, and only if there was a new character present in one of the table states would a different hash be calculated.
Also made a few formatting improvements, firstly
table_state()was modified to return the prettified representation of table state which matches the format that_check_table_difference()uses for diffing. Secondly, the order in which flowmods are printed for a table is now sorted by priority then by match.