Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

assert(uv_thread_self() == map_thread) #623

Closed

Description

@mikemorris

These asserts (scattered throughout a few different files) should not be expected to pass when the Map::render is intentionally called in a different thread than where the map object was initially created (such as an async render method in Node.js bindings). I saw some logic around an async_render function, but that seems to be tied into the libuv implementation in mapbox-gl-native a bit too closely. Should this either be refactored for external use, or should these asserts be conditionally disabled some other way?

Activity

  1. ljbade commented on Nov 22, 2014

    @ljbade
    Contributor

    Yeah came across this problem in a few places with other functions.

  2. mikemorris commented on Dec 18, 2014

    @mikemorris
    ContributorAuthor

    In the cli-render branch, the problematic asserts only seem to be present on BUILDTYPE=Debug installs now, fixed by 57e6bc6. Is there a better way to patch this to still be able to get debug symbols in Node.js bindings though @kkaefer? I'm guessing Mode::Static from 21e9e0a might be part of the answer.

  3. mikemorris commented on Dec 18, 2014

    @mikemorris
    ContributorAuthor

    Doh, this is apparently only happening in Debug builds? Just ran against a Release build of master without tripping any asserts.

  4. ljbade commented on Dec 18, 2014

    @ljbade
    Contributor

    @mikemorris assert() compiles to a noop on Release builds

  5. mikemorris commented on Dec 18, 2014

    @mikemorris
    ContributorAuthor

    Hah, that would do it, was that a recent change or has it always been that way @ljbade?

  6. incanus commented on Dec 19, 2014

    @incanus
    Contributor

    That's pretty common native behavior.

  7. kkaefer commented on Dec 19, 2014

    @kkaefer
    Member

    asserts are always compiled out on Release builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions