Uploaded image for project: 'Appcelerator Studio'
  1. Appcelerator Studio
  2. TISTUD-7749

LiveView: Improve connection error messages

    Details

    • Type: Improvement
    • Status: Open
    • Priority: None
    • Resolution: Unresolved
    • Affects Version/s: Release 4.3.1
    • Fix Version/s: None
    • Component/s: LiveView
    • Labels:
      None

      Description

      Following out of TISTUD-7747 we should improve LiveView error messages which are not a clear 404 telling us that the requested module id is not a commonjs module at which point the original require will try to use a native module and ultimately fail saying it didn't find one.

      In _getRemoteSource I think it should be something like the following:

       
          if (request.readyState === 4 || request.status === 404 || (expireTime - (new Date()).getTime()) <= 0) { 
            rsp = (request.status === 200) ? request.responseText : false; 
            done = true; 
            if (request.status !== 200 && request.status !== 404) { 
            	throw new Error('[LiveView] File Server unavailable. Host Unreachable @ ' + Module._url + ':' + Module._port + '\n[LiveView] Please ensure your device and computer are on the same network and the port is not blocked.'); 
            } 
          } 
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kkolipaka Kondal Kolipaka (Inactive)
                Reporter:
                fokkezb Fokke Zandbergen
              • Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: