2 Replies Latest reply on Apr 20, 2017 10:32 PM by Max Ott

    Getting lots of error messages by just loading tableauwdc-2.2.latest.js

    Max Ott

      I'm just including 'tableauwdc', not making any calls on the library and I already end up with a lot of error messages. From looking

      into the code a bit further, it appears that the script assumes it is alone in the world and any events sent to 'window' are for it. Which is

      not the case for me on Chrome as the development extensions also produces a few events.

       

      But there seems to be something else going on as it first logs ' Initializing shared WDC' (line 5) and then logs an error 'Shared.js:43 No WDC registered.' in line 7. And unfortunately the same error is being thrown when I do finally want to submit something.

       

      Any ideas what is going on here?

       

      tableauwdc.js:63 Version Bootstrap is not defined, Initializing SimulatorDispatcher

      SimulatorDispatcher.js:16 Initializing message handling

      SimulatorDispatcher.js:232 Initializing public interface

      SimulatorDispatcher.js:278 Initializing private interface

      Shared.js:21 Initializing shared WDC

      SimulatorDispatcher.js:188 Received message!

      Shared.js:43 No WDC registered. Did you forget to call tableau.registerConnector?

      Shared._errorHandler @ Shared.js:43

      SimulatorDispatcher.js:192 Uncaught No WDC registered. Did you forget to call tableau.registerConnector?

      SimulatorDispatcher._receiveMessage @ SimulatorDispatcher.js:192

      SimulatorDispatcher.js:88 Uncaught Looks like the WDC is calling a tableau function before tableau.init() has been called.

      SimulatorDispatcher._sendMessage @ SimulatorDispatcher.js:88

      SimulatorDispatcher._abortWithError @ SimulatorDispatcher.js:252

      Shared._errorHandler @ Shared.js:57

      SimulatorDispatcher.js:188 Received message!

      Shared.js:43 No WDC registered. Did you forget to call tableau.registerConnector?

      Shared._errorHandler @ Shared.js:43

      SimulatorDispatcher.js:192 Uncaught No WDC registered. Did you forget to call tableau.registerConnector?

      SimulatorDispatcher._receiveMessage @ SimulatorDispatcher.js:192

      SimulatorDispatcher.js:88 Uncaught Looks like the WDC is calling a tableau function before tableau.init() has been called.

      SimulatorDispatcher._sendMessage @ SimulatorDispatcher.js:88

      SimulatorDispatcher._abortWithError @ SimulatorDispatcher.js:252

      Shared._errorHandler @ Shared.js:57

        • 1. Re: Getting lots of error messages by just loading tableauwdc-2.2.latest.js
          Brendan Lee

          I think the simulator assumes it has a valid WDC at the get go, this isn't the best assumption as it would be nice if it wasn't so noisy to just include the library. 

           

          The first received message at least is caused by that assumption.  When I try and repro on my machine I don't see the second message received that you are seeing.  Can you see what the message is?  

           


          If you just want to fix the errors, include the basic shell of a WDC in your javascript.

           

          (function () {
             var myConnector = tableau.makeConnector();

             myConnector.getSchema = function (schemaCallback) {

             };

             myConnector.getData = function (table, doneCallback) {

             };

             tableau.registerConnector(myConnector);
          })();

          • 2. Re: Getting lots of error messages by just loading tableauwdc-2.2.latest.js
            Max Ott

            Hi Brendan,

             

            Yes, the second message was my own fault as I confused myself by switching back and force from running it standalone vs. in the simulator. The reason for having to switch is that the simulator is aggressively closing down the window and with it the debugger. I haven't found a good solution for that , except hacking the simulator (which I want to avoid).

             

            What does confuse me in the error message is the mentioning of 'tableau.init()'. I'm not sure if this function actually exists. Anyway, I'll keep on digging.