Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-134115

Containers next to chunk borders can lose items when upgrading

    • Confirmed

      1. Create a world in 1.12.2
      2. Put a large chest in a chunk edge and fill it with blocks
      3. Open it in 1.13 and half the chest content will disappear

      I am facing west when placing the chest if that makes sense. I have two item frames on it as well.

        1. 2018-07-19_06.50.42.png
          2018-07-19_06.50.42.png
          53 kB
        2. 2018-07-19_06.50.58.png
          2018-07-19_06.50.58.png
          123 kB
        3. 2018-07-19_06.51.02.png
          2018-07-19_06.51.02.png
          415 kB
        4. 2018-09-27_15.45.40.png
          2018-09-27_15.45.40.png
          756 kB
        5. MC-134205_3.zip
          815 kB
        6. MC-134205_4.zip
          422 kB

          [MC-134115] Containers next to chunk borders can lose items when upgrading

          I think the fix was added to different forks of the codebase at once, hence why two fixes were set. Because they were already working on 1.14 before they made this change to the 1.13 branch

           

          [Helper] Jack McKalling added a comment - I think the fix was added to different forks of the codebase at once, hence why two fixes were set. Because they were already working on 1.14 before they made this change to the 1.13 branch  

          Future Version - 1.14 should be removed from fix versions, as it's fixed in 1.13.2-pre1.

          user-f2760 (Inactive) added a comment - Future Version - 1.14 should be removed from fix versions, as it's fixed in 1.13.2-pre1.

          [Mod] md_5 added a comment -

          I'd like to propose a different fix that gets closer to the root of the issues and fixes it more broadly, namely:

           

          1. Tile entities get added to chunks with mutable block positions that are then later changed by the converter, resulting in bad state
          2. The ordering of access across chunks is not well defined, and the converter may run conversions back and forth across different pairs of chunks depending on how the bordering edges are populated (e.g. a chunk with tiles crossing over on all edges).

           

          https://hub.spigotmc.org/stash/projects/SPIGOT/repos/craftbukkit/commits/eea43870346d11b7f8cf6cc4bf516e406c3ec006

          [Mod] md_5 added a comment - I'd like to propose a different fix that gets closer to the root of the issues and fixes it more broadly, namely:   Tile entities get added to chunks with mutable block positions that are then later changed by the converter, resulting in bad state The ordering of access across chunks is not well defined, and the converter may run conversions back and forth across different pairs of chunks depending on how the bordering edges are populated (e.g. a chunk with tiles crossing over on all edges).   https://hub.spigotmc.org/stash/projects/SPIGOT/repos/craftbukkit/commits/eea43870346d11b7f8cf6cc4bf516e406c3ec006

          Aikar added a comment - - edited

          After many hours of taking cracks at this, I finally figured it out

          This is now fixed in Paper version 275+

          https://papermc.io/ci/job/Paper-1.13/

          I sent to Dinnerbone and Grum, but for anyone else interested, here is the fix:

          https://gist.github.com/aikar/5da731bc0fb3dbd322fac5d15689ffef

           

          Aikar added a comment - - edited After many hours of taking cracks at this, I finally figured it out This is now fixed in Paper version 275+ https://papermc.io/ci/job/Paper-1.13/ I sent to Dinnerbone and Grum, but for anyone else interested, here is the fix: https://gist.github.com/aikar/5da731bc0fb3dbd322fac5d15689ffef  

          Intelli added a comment -

          AFAIK, the current issue only affects double wide containers that span two chunks (i.e. double chests).

          Intelli added a comment - AFAIK, the current issue only affects double wide containers that span two chunks (i.e. double chests).

          Does this only work for containers that hold items (dispensers, droppers, chests), or does it also work for blocks containing data like command blocks? Also, I know it works for chests, but what about the other containers I mentioned?

          Patrick McCarthy added a comment - Does this only work for containers that hold items (dispensers, droppers, chests), or does it also work for blocks containing data like command blocks? Also, I know it works for chests, but what about the other containers I mentioned?

          seema added a comment - - edited

          in 1.13.1 a chest lost a half inventory if it stay between 2 chunks (after world convert from 1.12.2)

          if a chest on the border from a chunk but inside, that worked now (it was a problem in 1.13.0)

          so world convertation is not save in 1.13.1 and need to be fixed

          seema added a comment - - edited in 1.13.1 a chest lost a half inventory if it stay between 2 chunks (after world convert from 1.12.2) if a chest on the border from a chunk but inside, that worked now (it was a problem in 1.13.0) so world convertation is not save in 1.13.1 and need to be fixed

          I've just ran a few tests using Mart's 1.12.2 test world.

          I first loaded/upgraded it in 1.13, where none of the chest contents were wiped.

          I then loaded/upgraded it in 1.13.1, where several halves of the double chests were wiped.

          I then retried it in both 1.13 and 1.13.1, each yielding the same results as above. (with the exact same chest locations wiped in 1.13.1 as before).

          I loaded the un-upgraded version in 1.12.2 and removed the opposite halves of the double chests, which are not wiped in upgrading to 1.13.1, leaving just the single chests which are usually wiped in the upgrade. When loading this in 1.13.1, they were not wiped.

           

          Zedadias Wick added a comment - I've just ran a few tests using Mart's 1.12.2 test world. I first loaded/upgraded it in 1.13, where none of the chest contents were wiped. I then loaded/upgraded it in 1.13.1, where several halves of the double chests were wiped. I then retried it in both 1.13 and 1.13.1, each yielding the same results as above. (with the exact same chest locations wiped in 1.13.1 as before). I loaded the un-upgraded version in 1.12.2 and removed the opposite halves of the double chests, which are not wiped in upgrading to 1.13.1, leaving just the single chests which are usually wiped in the upgrade. When loading this in 1.13.1, they were not wiped.  

          Mart Ratas added a comment -

          I was made aware on discord that this is actually a different issue (i.e chests ACROSS chunk borders not NEXT TO them). I initially failed to understand that (even though it is quite clear, especially from the picture provided).

           

          Is there a new 1.13.1 issue already tracked for this? I couldn't find one.

          Or should one be made?

          Mart Ratas added a comment - I was made aware on discord that this is actually a different issue (i.e chests ACROSS chunk borders not NEXT TO them). I initially failed to understand that (even though it is quite clear, especially from the picture provided).   Is there a new 1.13.1 issue already tracked for this? I couldn't find one. Or should one be made?

          [Mod] md_5 added a comment -

          Thanks Mart!

           

          I can confirm the same issue on my end - several of the chests are only half full in 1.13.1

          [Mod] md_5 added a comment - Thanks Mart!   I can confirm the same issue on my end - several of the chests are only half full in 1.13.1

            fry [Mojang] Georgii Gavrichev
            maol3 Martin Olofsson
            Votes:
            52 Vote for this issue
            Watchers:
            39 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: