Skip to content

import side-effect disables promise trampoline breaking DataLoaders #67

Open
@AllexVeldman

Description

@AllexVeldman

On import channels_graphql_ws, promise.promise.async_instance.disable_trampoline() is called, breaking DataLoaders.

In the code there is a reference to syrusakbary/promise#57 (comment) which indicates this is needed due to Promise not being thread-safe.

This should no longer be needed with promise ^2.3
syrusakbary/promise#81
https://github.com/syrusakbary/promise/releases/tag/v2.3.0

For some reason not completely clear to me yet this only impacts my unittests, the async_instance during normal operation seems to have trampoline_enabled=True.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions