1. #1
    Sencha User
    Join Date
    Sep 2012
    Posts
    8
    Vote Rating
    1
    dhennen is on a distinguished road

      1  

    Default Sencha cmd v3 production build fails (timeout) if not using sencha-touch-debug.js

    Sencha cmd v3 production build fails (timeout) if not using sencha-touch-debug.js


    I can build my app using sencha app build production if in app.json I use sdk/sencha-touch-debug.js.

    If instead I try sedk/sencha-touch.js, the build fails with the following error:
    [INFO] Copied resources/loading[INFO] Resolving your application dependencies (file:///ctdev/index.html)[ERROR] Timeout waiting for the application to finish loading[ERROR] Failed loading your application from: 'file:///ctdev/index.html'. Try setting the absolute URL to your application for the 'url' item inside 'app.json'

    Any thoughts?

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,408
    Vote Rating
    851
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Ext.Loader isn't enabled by default in none debug files therefore Sencha Cmd cannot resolve the required classes to include in the build.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Sep 2012
    Posts
    8
    Vote Rating
    1
    dhennen is on a distinguished road

      0  

    Default


    So is it possible to get Sencha Cmd to build the production target without using the debug version?

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,408
    Vote Rating
    851
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Correct, it needs Ext.Loader enabled to resolve what classes need to be included in the build.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Sencha User
    Join Date
    Sep 2012
    Posts
    8
    Vote Rating
    1
    dhennen is on a distinguished road

      0  

    Default


    Quote Originally Posted by mitchellsimoens View Post
    Correct, it needs Ext.Loader enabled to resolve what classes need to be included in the build.
    How does one enable that?

  6. #6
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,386
    Vote Rating
    138
    dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold

      0  

    Default


    There is no reason to swap out "sencha-touch-debug.js" for "sencha-touch.js" in your app.json because doing so may disable the loader among other things used in dev mode.

    The build process will effectively convert all code (app and framework) from debug mode to production mode.

    There are two ways for the compiler to determine dependencies for your application: the new way using the compiler's code analytics and the old way of running your app in a headless browser and capturing the loader history.

    Are you using "v2deps" mode? This is not the default so you would have to request it. The error message certainly appears to imply that you are using that mode, so either the v2 tools are running or this mode is enabled.

    Please include the exact command and result (including Cmd version banner) with "-debug" enabled.

    Such as:

    Code:
      $ pwd
      /ctdev
      $ sencha -debug app build production
      Sencha Cmd V3.0.0.181
      ...
    Thanks
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  7. #7
    Sencha User
    Join Date
    Sep 2012
    Posts
    8
    Vote Rating
    1
    dhennen is on a distinguished road

      0  

    Default


    Code:
    $ which sencha
    /Applications/SenchaSDKTools-2.0.0-beta3/sencha
    $ sencha  
    Sencha Command v2.0.2
    Copyright (c) 2012 Sencha Inc.
    ...
    I downloaded what I thought was the most recent version of the sencha command from http://www.sencha.com/products/sdk-tools/download/ but as you can see it reports version 2.0.2, not V3.0.0.181 you have.

    The -debug flag doesn't report anything extra on my version of sencha. However, here is the full build log:

    Code:
    $ sencha -debug app build -e production -d /tmp/ctlive[INFO] Deploying your application to /tmp/ctlive
    [INFO] Copied sdk/sencha-touch-debug.js
    [INFO] Copied app.js
    [INFO] Copied add2home.js
    [INFO] Copied resources/css/app.css
    [INFO] Copied resources/css/ctlive.css
    [INFO] Copied resources/css/add2home.css
    [INFO] Copied resources/images
    [INFO] Copied resources/loading
    [INFO] Resolving your application dependencies (file:////private/tmp/ctdev/index.html)
    [INFO] Found 232 dependencies. Concatenating all into '/tmp/ctlive/app.js'
    [INFO] Processed sdk/sencha-touch-debug.js
    [INFO] Minifying sdk/sencha-touch-debug.js
    [INFO] Processed app.js
    [INFO] Minifying app.js
    [INFO] Processed add2home.js
    [INFO] Minifying add2home.js
    [INFO] Minifying resources/css/app.css
    [INFO] Minifying resources/css/ctlive.css
    [INFO] Minifying resources/css/add2home.css
    [INFO] Minified resources/css/add2home.css
    [INFO] Minified resources/css/ctlive.css
    [INFO] Minified sdk/sencha-touch-debug.js
    [INFO] Minified add2home.js
    [INFO] Minified app.js
    [INFO] Generated delta for: 'app.js' from hash: 'cddbf16bac76ddd1282cf9ccccf10dbe09483bb3' to hash: '87e184960f6e4ba08a179787daa11140af07de23'
    [INFO] Minified resources/css/app.css
    [INFO] Generated app.json
    [INFO] Embedded microloader into index.html
    [INFO] Generating checksum for appCache item: index.html
    [INFO] Generated cache.manifest
    Where does one get v3 of the sencha command?

    Thank you very much for your help. Things are starting to make a little more sense now.

  8. #8
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,386
    Vote Rating
    138
    dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold

      0  

    Default


    That makes more sense

    The new version is in beta and can be found here:

    http://www.sencha.com/forum/showthre...ha-Cmd-V3-Beta

    When we reach GA we will update the main site pages.

    So, if you are using the Sencha Touch 2.1 Beta 3, then Sencha Cmd V3 (currently 3.0.0.181) is what you need.

    The SDK Tools V2 are needed for Sencha Touch 2.0 since the new Cmd is not backwards compatible (as of yet anyway).
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

  9. #9
    Sencha User
    Join Date
    Sep 2012
    Posts
    8
    Vote Rating
    1
    dhennen is on a distinguished road

      0  

    Default


    Okay, makes perfect sense now.

    I put v3 in my subject thinking Beta 3 == v3.

    I'm looking forward to GA. Thanks!