Skip to content
This repository was archived by the owner on Jan 10, 2021. It is now read-only.
This repository was archived by the owner on Jan 10, 2021. It is now read-only.

await sometimes deadlocks #68

@NeoLegends

Description

@NeoLegends

I'm really not sure why, but in some / most cases, awaiting a SpotiFire-object causes a deadlock. The await never completes. We should check whether this is because the library never sets is_loaded to true, or because of threading issues.

At the moment I'm working around this problem by doing a manual wait. It's dead ugly though, especially since this is exactly what the await was introduced for.

while (!resource.IsLoaded) {
    await Task.Delay(50);
}

I'm using WPF btw, so the continuations will be run on the current Dispatcher.

EDIT: await only seems to fail on the PlaylistContainer, not on the resources that are loaded via IAsyncLoaded.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions