Generate Sencha Touch App Failed - extjs

I'm having problem generating new Sencha Touch application. I already downloaded the Sencha SDK, Ruby and Sencha CMD. When I use sencha the sencha version and help are printed.
When I use the ff command to generate Sencha Touch application I encountered Build Failed:
sencha -sdk [sencha sdk location] generate app -name MyApp -path [project location]
Issue:
Sencha Cmd v5.0.1.231
[INF] Processing Build Descriptor : default
[INF] Loading app json manifest...
[ERR] Failed to resolve dependency Ext.app.Application for file MyApp.app.$Application
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.app.Application
[ERR] at org.apache.tools.ant.Project.e
[ERR] xecuteSortedTargets(Project.java:1399)
[ERR]
[ERR] Total time: 1 second
[ERR]
[ERR] BUILD FAILED
[ERR] (installation dir)\bin\Sencha\Cmd\5.0.1.231\plugin.xml:303: The following error occurred while executing this line:
[ERR] (installation dir)\bin\Sencha\Cmd\5.0.1.231\plugins\touch\2.3\plugin.xml:334: The following error occurred while executing this line:
[ERR] (installation dir)\workspace-sencha\.sencha\app\build-impl.xml:373: The following error occurred while executing this line:
[ERR] (installation dir)\workspace-sencha\.sencha\app\init-impl.xml:258: com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.app.Application
[ERR] at sun.reflect.GeneratedMethodAccesso
[ERR] r23.invoke(Unknown Source)
[ERR]
[ERR] Total time: 5 seconds
[ERR] The following error occurred while executing this line:
(installation dir)\bin\Sencha\Cmd\5.0.1.231\plugins\touch\2.3\plugin.xml:334: The following error occurred while executing this line:
(installation dir)\workspace-sencha\.sencha\app\build-impl.xml:373: The following error occurred while executing this line:
(installation dir)\workspace-sencha\.sencha\app\init-impl.xml:258: com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.app.Application
I'm already 3 days on this, not sure if I miss something.
Thanks in advance!

try use -d option to see more detail first
sencha -d -sdk [sencha sdk location] generate app -name MyApp -path [project location]

Related

ExtJS 6 modern "CODE" package build Sass compiler error

Using Sencha Cmd v6.5.0.180
From workspace home
sencha generate package --type=CODE --framework=ext --toolkit=modern my-menu
cd packages/local/my-menu
sencha package build
This works fine, however when I add an extension of Ext.panel.Panel
Ext.define('My.menu.Header', {
extend: 'Ext.panel.Panel',
....
I now get fashion/sass compilation errors.
Is there additional setup needed in the package.json to tell the app build where to find sass resources (I want to use 'theme-material') or should I be disabling sass compilation for a package build, or something else?
Output:
[INF] appending sass content to C:\app\src\main\webapp\x6\packages\local\app-menu\build\app-menu-all-debug.scss
[INF] appending sass content to C:\app\src\main\webapp\x6\packages\local\app-menu\build\app-menu-all-debug.scss
[INF] Building C:\app\src\main\webapp\x6\packages\local\app-menu\build\app-menu-all-debug.scss to C:\app\src\main\webapp\x6\packages\local\app-menu\build\resources\app-menu-all-debug.css
[LOG] Fashion build starting for C:\app\src\main\webapp\x6\packages\local\app-menu\build\app-menu-all-debug.scss
[ERR] unknown definition for mixin named box-shadow : C:/web/src/main/webapp/x6/ext/packages/core/sass/etc/recipes/color.scss:202
[ERR] unknown definition for mixin named text-shadow : C:/web/src/main/webapp/x6/ext/packages/core/sass/etc/recipes/color.scss:205
[LOG] Build error for C:\app\src\main\webapp\x6\packages\local\app-menu\build\app-menu-all-debug.scss
{ Error: Sass compilation encountered 2 error(s)
at Object.raise (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\export\Base.js:131:17)
at Transpiler.transpile (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\Transpiler.js:1549:21)
at Context.convert (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\Context.js:42:34)
at C:\Cmd\6.5.0.180\js\node_modules\fashion\src\Builder.js:147:45
at SassFile.fireReady (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:426:17)
at C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:398:28
at SassFile.fireReady (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:426:17)
at C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:398:28
at SassFile.fireReady (C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:426:17)
at C:\Cmd\6.5.0.180\js\node_modules\fashion\src\SassFile.js:398:28 '$isFashionError': true }
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExBuild: Fashion build exited with code : 1
[ERR] at o
[ERR] rg.apache.tools.ant.Task.perform(Task.java:348)
[ERR]
[ERR] Total time: 8 seconds
[ERR] The following error occurred while executing this line:

Failed to resolve dependency Ext.grid.Panel on ExtJS 6.0

I am having the following error when trying to extend 'Ext.grid.Panel' which is shown in the example on Sencha official documentation. I used both classic, modern, universal framework and still it is not working.
Failed to resolve dependency Ext.grid.Panel for file Xmlgrid.view.main.Main
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.grid.Panel
[ERR] at o
[ERR] rg.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
[ERR]
[ERR] Total time: 65 minutes 56 seconds
[ERR] Error during rebuild : The following error occurred while executing this line:
C:\Users\nandeesh\workspace\Xmlgrid\.sencha\app\watch-impl.xml:4: The following error occurred while executing this line:
C:\Users\nandeesh\workspace\Xmlgrid\.sencha\app\build-impl.xml:380: The following error occurred while executing this line:
C:\Users\nandeesh\workspace\Xmlgrid\.sencha\app\init-impl.xml:403: com.sencha.exceptions.ExNotFound: Unknown definition for dependency : Ext.grid.Panel
[INF] Refresh complete in 0 sec. at 10:59:30 AM
I also have to fix this error with a 6.5.0 Sencha Cmd version and a 6.2.0 Ext JS version.
I answer certainly a bit late for you #random aspirer but for those who search actually here it is. The issue comes from your toolkit config defined in your app.json so :
- If you have this :
"toolkit" : "modern",
replace it by
"toolkit" : "classic",
Solution reference : https://www.sencha.com/forum/showthread.php?303033-Unknown-definition-for-dependency

Error building sencha app with cmd 4.2.1 when upgrade to 5.1

I've used Sencha 4.2.1 GPL and decided to purchase license.
When installed 5.1 and upgraded the cmd , now when I try to build my old apps I keep getting same errors, but the strange thing is that "sencha app watch" is working.
[INF] Compressing data with YuiJavascriptCompressor
[ERR] C2009: YUI Parse Error (missing while after do-loop body =>
; while ((t = t.parentNode) && 1 === t.nodeType);) -- unknown-file:149
290:25
[ERR] C2009: YUI Parse Error (Compilation produced 1 syntax errors. => null) --
unknown-file:2
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExBuild: Failed to compress input
[ERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown So
[ERR] urce)
[ERR]
[ERR] Total time: 12 seconds
[ERR] The following error occurred while executing this line:
D:\Customer Projects\GIS\.sencha\app\build-impl.xml:255: The following error occ
urred while executing this line:
D:\Customer Projects\GIS\.sencha\app\js-impl.xml:53: com.sencha.exceptions.ExBui
ld: Failed to compress input
[ERR]
The application was last modified by an older version of Sencha Cmd (4.0.1.45)
the current is 5.1.0.26.
Please run "sencha app upgrade" to update to 5.1.0.26.
After upgrading I get these error :
[WRN] C1019: Namespace conflicts with defined class name (Class Ext.Toolbar used
as namespace by Ext.Toolbar.TextItem) -- D:\Customer Projects\GIS\
ext\src\toolbar\Toolbar.js:208
[INF] Compressing data with YuiJavascriptCompressor
[ERR] C2009: YUI Parse Error (missing while after do-loop body =>
; while ((t = t.parentNode) && 1 === t.nodeType);) -- unknown-file:146
756:25
[ERR] C2009: YUI Parse Error (Compilation produced 1 syntax errors. => null) --
unknown-file:2
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExBuild: Failed to compress input
[ERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown So
[ERR] urce)
[ERR]
[ERR] Total time: 10 seconds
[ERR] The following error occurred while executing this line:
D:\Customer Projects\GIS\.sencha\app\build-impl.xml:266: The follow
ing error occurred while executing this line:
D:\Customer Projects\GIS\.sencha\app\js-impl.xml:71: com.sencha.exc
eptions.ExBuild: Failed to compress input
How can I build the app or do I need to downgrade back to cmd 4?
EDIT
I've uninstalled Sencha Cmd 5 and managed to build with 4... weird.
It's failing when using YUI Compressor on the code near:
YUI Parse Error (missing while after do-loop body =>
; while ((t = t.parentNode) && 1 === t.nodeType);) -- unknown-file:146
I don't know why it gives you the filename as "unknown-file" but you should just be able to do a search in your project source code for 1 === t.nodeType and it should narrow it down.

Build Failure While trying to build App using Sencha Cmd

I am new to sencha cmd as per the documentation I am able to generate the application structure but when i start to build the app using sencha app build, Iam facing the following excpetion.
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExProcess: Failed creating background process
[ERR] onDevelopments\ExtJsProjects\Test\build\temp\production\Test\sass"): Creat
eProcess error=2, The system cannot find the file specified
[ERR]
[ERR] Total time: 19 seconds
[ERR] The following error occurred while executing this line:
E:\Softwares & Frameworks\MyApplicationDevelopments\ExtJsProjects\Test\.sencha\a
pp\build-impl.xml:284: The following error occurred while executing this line:
E:\Softwares & Frameworks\MyApplicationDevelopments\ExtJsProjects\Test\.sencha\a
pp\sass-impl.xml:155: The following error occurred while executing this line:
E:\Softwares & Frameworks\MyApplicationDevelopments\ExtJsProjects\Test\.sencha\a
pp\sass-impl.xml:176: com.sencha.exceptions.ExProcess: Failed creating backgroun
d process
I am able to find the file in specified loacation. Kindly help me ..
This is probably because Ruby and Compass are not installed on the system. I used steps described in the following link to fix this issue on my Linux RHEL:
https://www.rosehosting.com/blog/install-ruby-sass-and-compass/
Hope it helps.

How can I configure the sencha app build command to use a custom named app folder?

I need to use a custom named 'app' folder for my Ext JS 4.1.3 application. Sencha documentation is clear that this folder name is a configurable value called 'appFolder'.
Environment:
Ext JS 4.1.3
Sencha Cmd 3.1.2.342
Ruby 1.9
Steps that I took:
sencha generate workspace C:\temp\workspace
sencha -sdk C:\tools\extjs4.1.3 generate app common C:\temp\workspace\common
cd C:\temp\workspace\common
sencha app build
SUCCESSFUL
edited the app.js and set appFolder: 'custom':
Ext.application({
appFolder: 'custom' ...
Also renamed the 'C:\temp\workspace\common\app' folder to 'C:\temp\workspace\common\custom'
sencha app build.
[ERR] def was null
[ERR] failed to find meta class definition for name common.controller.Main
[ERR] def was null
[ERR] failed to find meta class definition for name common.view.Viewport
[ERR] C2008: Requirement had no matching files (common.view.Viewport) -- unknown
-file:-1
[ERR] Error executing page compilation Failed to find any files for C:\TEMP\workspace\common\app.js::ApplicationAutoDependency::common.view.Viewport
[ERR]
[ERR] BUILD FAILED
[ERR] com.sencha.exceptions.ExBuild: com.sencha.exceptions.ExBuild: Failed to find any files for C:\TEMP\workspace\common\app.js::ApplicationAutoDependency::common.view.Viewport
[ERR]
[ERR] Total time: 6 seconds
[ERR] The following error occurred while executing this line:
C:\TEMP\workspace\common\.sencha\app\build-impl.xml:408: The following error occurred while executing this line:
C:\TEMP\workspace\common\.sencha\app\build-impl.xml:381: com.sencha.exceptions.ExBuild: com.sencha.exceptions.ExBuild: Failed to find any files for C:\TEMP\workspace\common\app.js::ApplicationAutoDependency::common.view.Viewport
Edit file yourAppFolder/.sencha/app/sencha.cfg
Change classpath=${app.dir}/app to classpath=${app.dir}/custom

Resources