mojira.dev
MCPE-48054

Redstone dust on chunk borders can lose ability to power block in adjacent chunk, when reloading an area

Title updated by GoldenHelmet
Steps to reproduce given in this comment. A simpler version has been been provided in this comment.
Additional findings given in this comment and following.

Original title
Redstone Torches Can Break, When Reloading The Area
Original description
Occasionally when you reload an area of the world, redstone torches can break in a weird way. This typically happens when they are powering redstone dust, and the torch its self can be turned off bu the redstone circuit.

Its a hard one to explain, but it happens pretty frequently on realms, and it breaks LOADS of redstone contraptions!

Below you can find an image of a auto-sorters clock being broken from this bug, and a full demo in a video i made!
https://youtu.be/yU2IXXU6UzA?t=479

Related issues

Attachments

Comments

migrated
[media][media][media][media][media][media][media][media][media][media][media][media][media][media][media][media]
migrated

If I unload an area with redstone dust line powered up, on a single player world, it’ll appear like unpowered when I come back

migrated

I have had a similar issue where every redstone torch, repeater, Comparator, observer and button in my base had to lifted and replaced. 

[Mod] OcelotOnesie

Is this still an issue in the latest version?

migrated

I’ve experienced this issue as well. My issue report is a little more detailed, so I’ll post it here. It says, “ Something very strange is happening with redstone torches lately. Normally, a torch would turn off when the block it’s attached to receives a redstone signal. It still does this, but only to an extent. It’ll work, until you leave and reload into the world. After that, for some reason, it’ll only turn off when the signal strength that the torch is receiving is at it highest possible strength, 15. Any lower, and the torch will stay on. What’s weirder is that once you change anything to the circuit, like breaking and re-placing a redstone dust or torch, it’ll work again. What’s even WEIRDER is that when I discovered this issue, another NOT gate right next to the one that was having this issue was working just fine. I think it might have to do with direction? The buggy NOT gate had the torch facing east, with the normal working one facing west.”

migrated

Is this happens in 1.15.0.54 ?

[Mojang] Mega_Spud (Jay)

Would it be possible to get a test world where this is happening?

GoldenHelmet

The circuit in the OP's video and picture crosses a chunk border from Z=991 to Z=992. This may or may not be relevant, as the other circuits parallel to it all cross the same chunk border. Do they all break at once, or not?

 

Update: I have reproduced this bug in 1.14.30 using a setup like the OP’s that crosses a chunk border in the same place:

[media]

Test world attached: 

[media]

Steps to reproduce:

  1. Set render distance to 12.

  2. Open the attached test world. The circuit will begin cycling.

  3. Find the command block near the circuit. When the second repeater lights, but before the third repeater lights, push the button. This will teleport you 12 chunks west, near another command block.

  4. Save and quit.

  5. Reload the world.

  6. Turn all the way around slowly to make sure all chunks within render distance load.

  7. Push the button on the command block near you. This will teleport you 24 chunks east, where you will find a third command block.

  8. Save and quit again.

  9. Reload the world.

  10. Turn all the way around slowly to make sure all chunks within render distance load.

  11. Push the button on the command block near you. This will teleport you back to the start, by the circuit, which should now be locked with both sides on.

migrated

I didn't manage to reproduce the bug in 1.16.0.55. Tell me if I wrong and test it with newer versions please.

GoldenHelmet

I don't have the beta. Did you try it in the test world I uploaded? I just added some more detail to the steps.

GoldenHelmet

With further testing on the stuck circuit I've found that the bug is in the link between the redstone dust on the left and the block it runs into, the one holding the torch. There is no bug in the redstone torch. Instead, the bug is that the opaque block loses the ability to receive redstone updates from the dust in the neighboring chunk, or, equivalently, the redstone dust loses the ability to transfer redstone updates to the opaque block across the chunk border.

This video shows that the block holding the torch has a power level of 0, and adding an additional power source and/or changing the signal strength of the redstone dust has no effect on it: 

[media]

This video shows that a block update on the redstone dust triggers a redstone update in the stuck block:

[media]

This video shows that a block update on the stuck block does not trigger a redstone update, but a redstone update to the block in the form of adding a new power consumer does update the block:

[media]



Update: a redstone lantern only updates the block when placed on top, not when placed to the side! I now think that it is actually triggering a block update on the redstone dust, and not any kind of update on the concrete block. Demo: 

[media]



I also think the bug consists in the redstone dust "forgetting" that it is pointing into the block whenever its chunk is loaded and the block's chunk is not. The following video shows that when the linkage is broken, the block can still be powered, and the block is still able to power the Redstone dust next to it. Only the redstone dust cannot power the block. 

[media]
GoldenHelmet

Updated report title based on findings in previous comment. (Original title was: "Redstone Torches Can Break, When Reloading The Area")

Replaced the test world with an improved version:

  • Added a 2nd circuit based on the duplicate report MCPE-64059.

  • Added signs to label the two circuits and guide with repro.

  • Replaced the blocks that lose redstone connectivity with black concrete so that they stand out.

The circuit from MCPE-64059 is distinct in these ways:

  • It's a linear dust-block connection, not a clock circuit.

  • The redstone dust is unpowered when it loses the ability to update the block.

  • You can sometimes reproduce the bug with this circuit just by walking to a neighboring chunk and relogging.

Added some videos of additional findings from testing the MCPE-64059 circuit:

[media]
  • shows that the bug is not in any of the particular power source blocks, as some players might assume (for example MCPE-17476 and possibly MCPE-39851).

[media]
  • shows that the the circuit can be reactivated by a nearby block update I would not have expected.

GoldenHelmet

It looks like a similar bug was reported in MCPE-17304 for other redstone components and fixed some time ago.

migrated

I think the reason for the block update making it work again is because if you place blocks somewhere where a redstone component could theoretically power them (or nearby sometimes), then the game recalculates what that component is powering or could be powering.

Redstone components keep a list of components that they're powering (probably for performance reasons). This list is updated when you place a block nearby that the game thinks it could power.

So the problem lies with the redstone torch powering it, not the dust or the other torch.

Powering the torch doesn't cause it to recalculate this list, only a block update to the torch or an update to something it's powering would cause this.

The reason the torch forgets it's powering something may be because the game doesn't save this information and it has to recalculate this when it's loaded again. The game not saving this information causes a bunch of other issues as well.

I ran into a similar problem with pistons being powered when they shouldn't be as well. Updating their power source caused them all to retract.

migrated

I've done some more testing and managed to reproduce it in my own world, along with finding out exactly what's causing the bug.

It appears it is not necessary to power the component while it is unloading or anything like that.

The reason it doesn't work for certain setups is because when the chunk next to the power source loads it updates the producer of the redstone signal and it will then recalculate which blocks it is powering. In other setups it doesn't cause the component to recalculate the blocks it's powering when the chunk is loaded, leading to this wierd behaviour.

The reason this bug happens is because the game calculates what components are powering when the chunk is first loaded, even if neighbouring chunks are unloaded. It doesn't realise it can power components in the neighbouring chunks. In certain circumstances, when a neighbouring chunk is loaded, it doesn't update certain components in the chunk next to them, leading to some components not realising that they're powering stuff in that chunk.

I've also attached an image of which setups cause this behaviour and which ones don't. I could supply a demo world if needed.

I would also like to suggest some potential fixes:

  • The game could recalculate what all the components in nearby chunks are powering whenever a chunk is loaded.

  • The game could wait until a certain area of chunks are loaded around a specific chunk before calculating what the components in that chunk are powering.

migrated

I've added a demo world with easier steps to reproduce this bug (

[media]

). You press the button that makes you face the same direction every time in the same spot (so chunk loading is consistent), relog and press the button on the second command block to teleport.

GoldenHelmet

I believe 77Tigers is correct. This is the picture he’s provided:

[media]

The common factor in the bugged circuits on the right is actually tripartite:

  1. The dust points across a chunk border into a solid block,

  2. The chunk with the solid block loads after the chunk with the dust, and

  3. The power source is not linked to any other redstone component across the chunk border.

The second properly updated circuit from the left of the picture shows the necessity of condition (3) above. In this circuit the redstone dust in the gray chunk apparently triggers remapping of the redstone power connections upon chunk loading as described by 77Tigers.

This also suggests that the cause of the buggy behavior lies in the game failing to treat solid blocks as potential redstone consumers/connectors when it loads the gray chunks. My earlier conclusion that 

[media]

was based on the fact that updating the dust updated the connection. However, it is now clear that you must

[media]

(you can even

[media]

if it powers in that direction). So now it appears that the bug is in the redstone remapping that occurs with chunk loading not taking proper account of solid blocks on chunk borders. Probably the fix for MCPE-17304 remains relevant in that whatever was done to fix that for components failed to include solid blocks. The fixes suggested by 77Tigers seem better though, especially the first–just have adjacent chunks remap redstone connections from their producers after any chunk loads.

migrated

I've done some more testing and it seems this can happen to repeaters powering stuff 2 chunks away (just about).

 

[media]
migrated

Fixed in beta 1.16.0.61

migrated

I can confirm this is fixed. For anyone interested: I think the game now updates any components that could power stuff in unloaded chunks when the chunks are loaded.

migrated

Hello, I'm playing on bedrock server (v 1.20.40).  I think I'm experiencing this bug. 

I have a storage system with a row of 16 chests being read by comparators in adjacent slices. In each slice, the comparator signal goes into a block with redstone dust on top. There's another block above the comparator also with redstone dust on top (I'll call this the upper redstone dust) so that the signal coming out of the comparator goes up to there. The chests are configured so that the redstone signal is level 2 and just reaches the upper redstone dust and activates it.

The upper redstone dust is on a chunk border.

I have a nether portal nearby and when I go into the nether and back to the storage room I find that the upper redstone dust in some of the slices (typically 1-4 of the 16 slices) is switched off when all the redstone dust around it is on. The chest configurations have not changed, the comparators are still active and giving a signal of 2 so all the upper redstone dust should be on. 

When I break the erroneous redstone dust and replace it, it turns on as expected.

I can repeat this and different slices turn off each time. It seems to be random as to how many and which slices are glitching.

silentwisperer

(Unassigned)

338087

Confirmed

Windows

window 10

chunk-loading, redstone-torch, redstone-update

1.16.0.59 Beta, 1.16.0.55 Beta, 1.11.4, 1.14.30 Hotfix, 1.14.60 Hotfix

1.16.0.61 Beta, 1.16.0

Retrieved