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

Implemented GreedyStringTiling workaround #2076

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

TwoOfTwelve
Copy link
Contributor

Implemented a check for the index out of bounds exception, that occurs occasionally.
It prevents the normal exception and throws one with more debug information

@tsaglam tsaglam added bug Issue/PR that involves a bug minor Minor issue/feature/contribution/change labels Nov 22, 2024
Copy link

@@ -30,6 +31,13 @@ public class GreedyStringTiling {
private final Map<Submission, int[]> cachedTokenValueLists = new IdentityHashMap<>();
private final Map<Submission, SubsequenceHashLookupTable> cachedHashLookupTables = new IdentityHashMap<>();

private static final String ERROR_INDEX_OUT_OF_BOUNDS = """
Copy link
Member

@Kr0nox Kr0nox Nov 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elaborate what index and length is printed.
Add information what two submissions are being compared (names)
Also print which of the two had the error

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would second that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue/PR that involves a bug minor Minor issue/feature/contribution/change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants