Skip to content

Update PathingStuckHandler.java#11646

Merged
someaddons merged 1 commit intoldtteam:version/1.21from
armele:stuckhandler_exception
May 2, 2026
Merged

Update PathingStuckHandler.java#11646
someaddons merged 1 commit intoldtteam:version/1.21from
armele:stuckhandler_exception

Conversation

@armele
Copy link
Copy Markdown
Contributor

@armele armele commented May 1, 2026

Closes #11643

Changes proposed in this pull request

  • Placed a simple check in PathingStuckHandler.tryUnstuck() to guard against the possibility of one of the retry paths attempting to index path node -1

Testing - prior to the fix I received:

Caused by: java.lang.ArrayIndexOutOfBoundsException: Index -1 out of bounds for length 33
        at java.base/java.util.Arrays$ArrayList.get(Arrays.java:4266) ~[?:?] {}
        at TRANSFORMER/minecraftnet.minecraft.world.level.pathfinder.Path.getNodePos(Path.java:97) ~[server-1.21.1-20240808.144430-srg.jar%23324!/:?] {re:classloading}
        at TRANSFORMER/minecoloniescom.minecolonies.core.entity.pathfinding.navigation.PathingStuckHandler.tryUnstuck(PathingStuckHandler.java:373)

clearly indicating the location. Post fix this did not occur.

Review please

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 1, 2026

In order for this pull request to be merged, make sure you test whether your changes work.

If the changes are working as intended, remove the https://github.com/ldtteam/minecolonies/labels/undefined label from the pull request.
As long as this label is on the pull request, it will not be merged.
If your pull request made no changes to the source code, the label will not be automatically added to the pull request.

Contributors, please review this pull request!

@armele
Copy link
Copy Markdown
Contributor Author

armele commented May 1, 2026

Please remove the "Untested" label.

@someaddons someaddons merged commit 3fa1090 into ldtteam:version/1.21 May 2, 2026
7 checks passed
someaddons pushed a commit that referenced this pull request May 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants