When a structure is extremely far from you, using the locate command will not give you the correct distance to the structure.
This error occurs when locating a stronghold. If you use the locate command to find a stronghold from a very far distance (possibly over 100,000), it will still show the correct coordinates but will not correctly display your distance from the structure. At this distance, no matter how far you are from the structure, it will always show that you are 0 blocks away from it.
In fact, knowing the coordinates of the stronghold and your coordinates and calculating the straight-line distance between the two is not difficult, but showing a distance of 0 blocks is simply wrong.
Thank you for your report!
We're tracking this issue in MC-177381, so this ticket is being resolved and linked as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki