# Sync in a loop can suspend forever if its first block doesn't suspend

**URL:** <https://forums.unrealengine.com/t/sync-in-a-loop-can-suspend-forever-if-its-first-block-doesnt-suspend/2069479>\
**Category:** Issues and Bug Reporting\
**Tags:** unreal-editor-for-fortnite, open, fortnite-creative, fortnite\
**Created:** [October 15, 2024, 1:18pm UTC](https://forums.unrealengine.com/t/sync-in-a-loop-can-suspend-forever-if-its-first-block-doesnt-suspend/2069479 "2024-10-15T13:18:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![im\_a\_lama](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/im_a_lama/32/995063_2.png) [@im\_a\_lama](https://forums.unrealengine.com/u/im_a_lama)\
**Post date:** [October 15, 2024, 1:18pm UTC](https://forums.unrealengine.com/t/sync-in-a-loop-can-suspend-forever-if-its-first-block-doesnt-suspend/2069479/1 "2024-10-15T13:18:08Z")

</div>

### Summary

Here’s the repro

```auto
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
test_device := class(creative_device):

    FakeSuspends()<suspends>:void=
        Print("FakeSuspends")

    OnBegin<override><final>()<suspends>:void=
        Print("BEFORE")
        loop:
            Print("A")
            sync:
                FakeSuspends()
                Sleep(0.0)
            Print("B")
        Print("AFTER")
        # Will print BEFORE / A / FakeSuspends / B / A / FakeSuspends and then nothing anymore

```

Here the script is supposed to Print in a loop but it stops after the 2nd iteration (no crash, it just suspends forever)

Swapping the two statements makes it work as intended

```auto
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
test_device := class(creative_device):

    FakeSuspends()<suspends>:void=
        Print("FakeSuspends")

    OnBegin<override><final>()<suspends>:void=
        Print("BEFORE")
        loop:
            Print("A")
            sync:
                Sleep(0.0) # Swapped
                FakeSuspends() # Swapped
            Print("B")
        Print("AFTER")
        # Will print BEFORE / (A / FakeSuspends / B) * infinite (as intended)

```

### Please select what you are reporting on:

Verse

### What Type of Bug are you experiencing?

Verse

### Steps to Reproduce

See the repro above

### Expected Result

See the repro

### Observed Result

See the repro

### Platform(s)

PC

---

<div class="post-metadata">

**Author:** ![Flak](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/flak/32/769441_2.png) [@Flak](https://forums.unrealengine.com/u/Flak)\
**Post date:** [October 15, 2024, 6:47pm UTC](https://forums.unrealengine.com/t/sync-in-a-loop-can-suspend-forever-if-its-first-block-doesnt-suspend/2069479/2 "2024-10-15T18:47:16Z")

</div>

We’ll get someone to take a look.

---

<div class="post-metadata">

**Author:** ![Bug-Reporter](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bug-reporter/32/1223650_2.png) [@Bug-Reporter](https://forums.unrealengine.com/u/Bug-Reporter)\
**Post date:** [July 21, 2026, 8:00pm UTC](https://forums.unrealengine.com/t/sync-in-a-loop-can-suspend-forever-if-its-first-block-doesnt-suspend/2069479/4 "2026-07-21T20:00:38Z")

</div>

FORT-805504 has been ‘Backlogged’. This is an issue that is in a queue to be addressed.
