-
Notifications
You must be signed in to change notification settings - Fork 280
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
StringSchema.hashCode inconsistent across executions #505
Comments
Hello @elrodro83 I pushed a fix in this commit: 5436bb7 Does it work for you? Do you need a release urgently? |
Hi! I retested and am still having failures even with this fix. The change seems to fix the |
possibly related. SchemaLoader.load() is giving inconsistent behavior. the issue seems to be isolated to 1.14.4, i wasn't able to reproduce in 1.14.3. to reproduce, i just ran this simple test:
which will eventually cause this:
my json object is quite large and complex, which might be exacerbating the issue. but with the same exact json, i am certain i'm only seeing this in 1.14.4. i also tried 5436bb7 - same thing |
This seems to happen because formatValidator is a lambda (https://github.com/everit-org/json-schema/blob/master/core/src/main/java/org/everit/json/schema/FormatValidator.java#L2), and lambdas d not have a fixed hashCode.
This is causing different runs to sort subschemas of a CombinedSchema differently, after this change: 81f0b2f#diff-66627cee53cd6d5d44872a44ab6dac6906bdf991afa3433ada63cbdea1466f63R177
The text was updated successfully, but these errors were encountered: