Results 1 to 4 of 4

Thread: Sencha CMD broken production build and modified original application

  1. #1
    Sencha User
    Join Date
    Dec 2016
    Pinar del Rio, Cuba

    Default Sencha CMD broken production build and modified original application

    Hello dear folks.
    I have been struggling in vain with this issue for a couple of days. Any help with this will be highly appreciated.
    I created an Ext JS 6.2.0 application from the beginning through the documented way using this command:

    sencha -sdk /path/to/ext6 generate app -ext -classic MyApp /path/to/my-app

    It worked fine. The CMD version is And I'm very happy with the checkbox of the classic toolkit.
    Then I created by hand and from scratch several models, stores, views, a viewModel and a viewController to have some basic functionalities in my app.
    At that point I did the development and production builds through these commands:

    sencha app build development
    sencha app build production

    I did that mostly because I was curious about the build results in terms of quantity, content and size of output files. Both build commands ran without problems and both output "directories" were perfectly "web browsable". As well as the original directory in which I wrote the original app source code, which also remained perfectly browsable, unchanged after building I would say.
    I continued extending the app functionalities without problems, always having in mind the so called compiler friendly guidelines, until I had them all done, point at which I put hands to work to do the final production build to deploy my app latter. With no special requirements from my part, I hadn't to modify any build config files, app json config files or such, so I only had to run the same command again:

    sencha app build production

    And there began my problems. The production build didn't work any more, in Firebug I can see several files loading OK until a file named ".js" (only a dot and the js extension without any file name) tries to load unsuccessfuly, of course, as it doesn't exist. But my biggest concern is that the original app in the original directory also got modified, at least one part of it, a window with a form, a fieldset and a grid. This window now looks "uggly", although it remains functional.
    This is the good one:
    And this is the bad one:
    Luckily I had a snapshot backup from the point after the first builds I said I did. I went restoring and trying one by one every "non app" file, until the troubled window looked great again. The trick was in these files:


    This "restoring" process sounds to me like an aberration, but it saved my life. But anyway I want to have my app in a clean and consisting state before building, so that I can live with ext-all.js in case the production build becomes my nightmare. And of course I would also like to be able to build, now that I know by my eyes that it is a great thing (from my first, successful try). So that are my questions, how to have my app back without any dependencies of anything from the build folder, as it was after my first build, and how to overcome these obstacles and do a successful production build without affecting the original app creating dependencies to build output files. Excuse being this verbose but I wanted to point out my questions clearly.
    I spent some hours reading line by line all my app js files and adding any required and missing stuff to the "requires" sections, and also checking in the web console that there were no warnings or errors, actually there were no warnings or errors even before doing this. All my classes are Ext.define'd and all my objects created inline are Ext.create'd, and not using the new operator.
    Just a note, I can't imagine if it's related to this, I have a css file, included in the index.html file, and declared as remote in the app.json file, so that it doesn't get minified or bundled, and after building I can still easely change some colors.
    Can anybody give any opinion on these issues, give any idea or point to some resource?
    Thanks a lot for your reading.

  2. #2


    Dear all, I'm experiencing exactly the same issue (and I followed the same steps):

    The production build didn't work any more, in Firebug I can see several files loading OK until a file named ".js" (only a dot and the js extension without any file name) tries to load unsuccessfuly, of course, as it doesn't exist

    sencha app watch

    I can browse the app and it works but when I build it, it doesn't work any more.

    How can this be solved?

    I'm using ExtJS 6.2.0 GPL and Sencha Cmd

    Thank you

  3. #3

    Join Date
    Jan 2008
    Levittown, PA


    Same issue. Deleting all of the app_name-all.css files from the build folder and then re-building did the trick.

  4. #4


    for the production build: sencha app build classic production

    Try to remove all imports from the 'requires' array and try to create components with Ext.create() or Ext.widget() - in this case they will be auto imported and the requests like " .js" will disappear

Similar Threads

  1. Replies: 3
    Last Post: 21 Feb 2017, 4:29 AM
  2. Replies: 8
    Last Post: 22 Jul 2015, 10:36 PM
  3. Replies: 4
    Last Post: 1 May 2015, 5:54 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts