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

equivalenceHash makes use of hashCode #724

Open
kwalcock opened this issue Mar 10, 2023 · 0 comments
Open

equivalenceHash makes use of hashCode #724

kwalcock opened this issue Mar 10, 2023 · 0 comments

Comments

@kwalcock
Copy link
Member

The equivalenceHash is used to generate IDs which get serialized. The value should be the same for the same documents and sentences, regardless of Java version or Scala version. In some places, "string".hashCode is used, but those values do seem to have been standardized in Java. Also used is directedGraph.equivalenceHash that calls edges.hashCode, which is not standardized. The edges are stored a fairly abstract List and the hashCode has changed between Scalas 2.11/12 and 2.13+. The code needs to be changed so that it only depends on the values and not the container.

The fix isn't scheduled yet, because it will break old hash codes and just now it is important to keep them for regression testing until it's clear that the json serialization changes are correct.

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

No branches or pull requests

1 participant