Success! Looks like we've fixed this one. According to our records the fix was applied for TOUCH-2416 in a recent build.
  1. #1
    Sencha - Training Team mrsunshine's Avatar
    Join Date
    Sep 2008
    Location
    Germany - Darmstadt
    Posts
    690
    Vote Rating
    12
    mrsunshine will become famous soon enough

      0  

    Exclamation Sencha command build ignores loader path definitions

    Sencha command build ignores loader path definitions


    U]REQUIRED INFORMATION[/U]




    Ext version tested:
    • Sencha Touch 2.0.0



    Browser versions tested against:
    • Safari 5.13



    DOCTYPE tested against:
    • ____



    Description:
    • Sencha Command does not resolve dependencies of modules with MVCS classes outside of the app folder while testing and production build proberly



    Steps to reproduce the problem:
    • create a new application with sencha command
    • add a custom module Mod1 with a MVCS structure folder and a controller file on the same level as the app folder
    • in app.js add the path to the module to the loader config
    • add the controller 'Mod1.controller.Mod1' to the application controller config
    • sencha app build testing







    The result that was expected:
    • working application in the build/testing/ folder



    The result that occurs instead:
    • Loading error in the browser of the custom Mod1 controller file
      Code:
      Mod1.js



    Test Case:


    Code:
    //<debug>
    Ext.Loader.setPath({
    'Ext' : 'sdk/src',
    'Mod1' : 'Modules/Mod1'
    		});
    
    
    // </debug>
    
    
    Ext.application({
    	controllers : ['PhoDo.controller.Homescreen', 'Mod1.controller.Mod1'],
    
    
    	name : 'PhoDo',
    
    
    	requires : ['Ext.MessageBox', 'Ext.app.Controller'],
    
    
    	views : ['Main'],
    
    
    	icon : {
    		57 : 'resources/icons/Icon.png',
    		72 : 'resources/icons/Icon~ipad.png',
    		114 : 'resources/icons/Icon@2x.png',
    		144 : 'resources/icons/Icon~ipad@2x.png'
    	},
    
    
    	phoneStartupScreen : 'resources/loading/Homescreen.jpg',
    	tabletStartupScreen : 'resources/loading/Homescreen~ipad.jpg',
    
    
    	launch : function() {
    // Destroy the #appLoadingIndicator element
    		Ext.fly('appLoadingIndicator').destroy();
    
    
    // Initialize the main view
    		Ext.Viewport.add(Ext.create('PhoDo.view.Main'));
    	},
    
    
    	onUpdated : function() {
    		Ext.Msg.confirm(
    "Application Update",
    "This application has just successfully been updated to the latest version. Reload now?",
    						function() {
    							window.location.reload();
    						});
    	}
    });
    
    



    File structure:

    • • app
      • controller
      • model
      • profile
      • store
      • view
    • Mod1
      • controller
      • model
      • profile
      • store
      • view
    • ...
    • index.html
    • app.js








    HELPFUL INFORMATION




    Screenshot or Video:
    • attached



    See this URL for live test case: http://




    Debugging already done:
    • seems that the set loader path info is ignored while running the testing/ production build



    Possible fix:
    • not provided



    Additional CSS used:
    • only default ext-all.css
    • custom css (include details)



    Operating System:
    • ________
    • OSX Lion

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,522
    Vote Rating
    814
    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


    We will look into testing this to ensure this can be done.
    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 - Sencha Touch Dev Team Jacky Nguyen's Avatar
    Join Date
    Jul 2009
    Location
    Palo Alto, California
    Posts
    469
    Vote Rating
    14
    Jacky Nguyen has a spectacular aura about Jacky Nguyen has a spectacular aura about

      0  

    Default


    Remove both //<debug> and //</debug> lines and it should just work.

    In fact the default Ext.Loader.setPath() statement shouldn't even be there when you generate the app, something I overlooked. This won't be an issue in the next release.
    Sencha Touch Lead Architect

  4. #4
    Sencha - Training Team mrsunshine's Avatar
    Join Date
    Sep 2008
    Location
    Germany - Darmstadt
    Posts
    690
    Vote Rating
    12
    mrsunshine will become famous soon enough

      0  

    Default


    Thanks, never thought the solution is such easy :-) after trying different things for hours

  5. #5
    Sencha User
    Join Date
    Mar 2012
    Location
    Novi Sad, Serbia
    Posts
    3
    Vote Rating
    0
    Sasa Popovic is on a distinguished road

      0  

    Default Is a new release available?

    Is a new release available?


    @Jacky, is a new release already available?

    @mrsunshine, how did you manage to make it work (where did you remove the debug lines)?

    Regards,
    Sasa

  6. #6
    Sencha - Sencha Touch Dev Team Jamie Avins's Avatar
    Join Date
    Mar 2007
    Location
    Redwood City, California
    Posts
    3,661
    Vote Rating
    21
    Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough Jamie Avins is a jewel in the rough

      0  

    Default


    The beta2 tools release is available here: http://www.sencha.com/forum/announcement.php?f=92&a=30

    There will be a new release next week for 2.0.1 final as well.

    Sencha Inc

    Jamie Avins

    @jamieavins

  7. #7
    Sencha User
    Join Date
    Mar 2012
    Location
    Novi Sad, Serbia
    Posts
    3
    Vote Rating
    0
    Sasa Popovic is on a distinguished road

      0  

    Default Still not working

    Still not working


    Thanks Jamie.

    I uninstalled SDK Tools 2.0.0, installed Beta 2, downloaded SDK 2.0.1. RC and upgraded my application to SDK 2.0.1 RC but the problem remains. No matter if I build for "testing" or "production", the dynamic loader will always try to download additional javascript files even though I already have them in my app.js.

    Was this issue already fixed in SDK Tools 2.0.0. Beta 2 or will it be fixed in SDK Tools 2.0.1. final?

    My website is still quite small and I used Console in Chrome to go through each single page and be sure that there are no errors or warnings anywhere. Is there anything else that I can try?

  8. #8
    Sencha User
    Join Date
    Mar 2012
    Location
    Novi Sad, Serbia
    Posts
    3
    Vote Rating
    0
    Sasa Popovic is on a distinguished road

      0  

    Default Reference to sencha-touch-all.js in app.json

    Reference to sencha-touch-all.js in app.json


    I managed to solve the issue by referencing sencha-touch-all.js instead of sencha-touch.js in app.json - I figured this out by looking at the kitchensink sample.

    Thanks for your replies.

  9. #9
    Sencha User
    Join Date
    Mar 2012
    Posts
    4
    Vote Rating
    0
    waynekempf is on a distinguished road

      0  

    Default Similar 404 Not Found issue after building with cmd 3.0 and ST 2.1

    Similar 404 Not Found issue after building with cmd 3.0 and ST 2.1


    Production build still tries to load individual app files using injectScriptEement.

    I can run index.html with microloader from the dev directory just fine.

    I ran sencha app build production OR package, with no errors.
    Build directory was updated as expected.
    But when I try to run the production or package index.html in the browser, the app fails and I get these results in web inspector:

    Creating Application Cache with manifest http://localhost:3000/build/production/cache.appcache
    Application Cache Checking event
    Application Cache Downloading event
    Application Cache Progress event (0 of 1) http://localhost:3000/build/production/index.html
    Application Cache Progress event (1 of 1)
    Application Cache Cached event
    ...and so on, one GET 404 error for every source file in my app.

    I know I could just copy those files into the build directory but of course that wouldn't make sense. I can see the app.js file produced by the build does contain the necessary ST 2.1 classes as well as my app classes.

    So...Why is the bootstrapping logic added to app.js by the build process invoking the Ext.apply.injectScriptEement for all the files that are already concatenated in app.js?

    What am I doing wrong?
    Many thanks!