Windy Community
    • Unread
    • Categories
    • Groups
    • Go to windy.com
    • Register
    • Login

    getLatLonInterpolator sometimes never executing the ".then" function

    Scheduled Pinned Locked Moved Windy Plugins
    3 Posts 2 Posters 1.0k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T Offline
      tomA27 | Premium
      last edited by

      Until recently, the following code (called within onRedrawFinished) worked properly. Following the recent update it now fails about 50% of the time in the sense that the updateInterpolator function never gets called. (I have never seen the "catch" happen in my testing)

      		getLatLonInterpolator().then((interpolator) => {
      			updateInterpolator(interpolator, model, overlay);
      		 }).catch((e) => {
      			console.log(e);
      			updateInterpolator(null, model, overlay);
      		 });
      

      This has a bad effect on the functionality within the SoarCalc plugin. Any help would be very gratefully received.

      rittelsR 1 Reply Last reply Reply Quote 0
      • rittelsR Offline
        rittels Code contributor @tomA27 | Premium
        last edited by

        @tomA27

        It appears as if W.broadcast("redrawFinished", ) , is no longer triggered by panning or zooming the map.

        Perhaps try using the leaflet listeneers.

        It also affects my plugins.

        T 1 Reply Last reply Reply Quote 0
        • T Offline
          tomA27 @rittels | Premium
          last edited by

          @rittels Thanks for the hint. I did wonder if this was happening and will now take another look as this will also have a bad effect in SoarCalc. For me, this has been masked by the worse problem that getLatLonInterpolator() fails (never resolves) some fraction of the time and I needed to add a timeout and fail gracefully.

          Right now I am struggling to work out why the "publish-plugin" action always fails with "Error: Process completed with exit code 22." This has happened before and I cannot for the life of me remember what I did to resolve it.

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          Windy Community  |  Powered by excellent NodeBB
          Terms of Use     Privacy Policy     Windy.com