PDA

View Full Version : SenchaCmd v3.0.0.190 - Build Failed: "Failed to find any files for ..."



LB82
19 Oct 2012, 5:36 AM
Hi,

I'm trying to build my app with the Sencha Cmd v3.0.0.190 on MacOs X, but cannot succeed.

Everytime I get an error for missing Dependencies.


I'm using Ext 4.1.1a and wrote an Ux-Class and the Build-Tool cannot resolve my path.
Running "sencha app build" from the application root. (not /app-Folder)

I've added
Ext.Loader.setPath('Dbc.ux.form.field', 'Dbc/ux/form/field'); to my app.js, and if I open the application within a Browser everything works fine.

Is there something I've missed?



Sencha Cmd v3.0.0.190[INFO ] init-properties:
[INFO ] init-sencha-command:
[INFO ] init:
[INFO ] -before-app-build:
[INFO ] app-build-impl:
[INFO ] Compiling page null
[INFO ] Processing classPath entry : /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/sencha-compile-temp-dir
[INFO ] Processing classPath entry : /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/ext/src
[INFO ] Processing classPath entry : /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/app
[WARN ] [ [1000] : Yui Compressor Warning <> Trailing comma is not legal in an ECMA-262 object initializer => ] ] :: ( /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/ext/src/ux/grid/filter/DateFilter.js => 133 : 25 )
[INFO ] Processing class inheritance graph
[INFO ] Processing instantiation refereces to classes and aliases
[WARN ] [ [1000] : Yui Compressor Warning <> Trailing comma is not legal in an ECMA-262 object initializer => ] ] :: ( /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/ext/src/ux/grid/filter/DateFilter.js => 133 : 25 )
[INFO ] Processing source dependencies
[ERROR] Failed to find file for Dbc.ux.form.field.SearchTrigger
required by /Users/lars/Desktop/htdocs/v6.1.telefonica.0/standard/std/dbc/quickAccess/app/view/seminar/SeminarSearch.js
[ERROR] Error executing page compilation com.sencha.exceptions.BasicException: com.sencha.exceptions.ExBuild: Failed to find any files for Dbc.ux.form.field.SearchTrigger
[ERROR] BUILD FAILED
[ERROR] com.sencha.exceptions.ExBuild: com.sencha.exceptions.BasicException: com.sencha.exceptions.BasicException: com.sencha.exceptions.ExBuild: Failed to find any files for Dbc.ux.form.field.SearchTrigger

mitchellsimoens
23 Oct 2012, 7:41 AM
Do you have the Ext.Loader.setPath('Dbc.ux.form.field', 'Dbc/ux/form/field'); within the //<debug and //</debug>? Should work fine but you can try to move it outside the comments

LB82
23 Oct 2012, 11:43 PM
I don't use any //debug comments.

My app.js starts with:


Ext.Loader.setPath('Dbc.ux.form.field', 'Dbc/ux/form/field');Ext.application({
name: 'QuickAccess',

requires:[
'Ext.state.Manager',
'Ext.state.CookieProvider'...


I've found a solution, that builds my app - but I don't know if it is the right way.

Edited the .sencha/workspace/sencha.cfg and added


workspace.classpath=${workspace.dir}/Dbc

With this line I don't need to use "setPath"

dongryphon
24 Oct 2012, 11:32 PM
Using the classpath is the ideal solution for the compiler. There are two you can use here. The one you found would apply to all applications in the workspace. If you only have the one application then the workspace and application folders are probably the one and the same. The other location is in the ".sencha/app/sencha.cfg" file.

For reference, these files in the ".sencha" folder can be used by any application even ones not generated by Sencha Cmd. The easiest way to create them is to generate a dummy app and copy the ".sencha" folder.

dongryphon
24 Oct 2012, 11:35 PM
I should mention that for generated applications, the set of all files and their aliases etc are tracked in a "bootstrap" file. The "sencha app refresh" updates this and should be run if new files are added, files are removed or other file system changes may invalidate this data.

You can decide if the bootstrap file should be version controlled or generated locally but ignored.

You can also manually create such a file using the compiler. See http://docs.sencha.com/ext-js/4-1/#!/guide/command_app_single for a start on that in a non-generate app.

stewardsencha
16 Dec 2012, 11:58 AM
I arrived at the same idea but it's not flying for me.



steward$ sencha compile -classpath=ext4/src,ext4/examples/ux/grid,util,lib,upc/app, \
> concat build/upc/wtf.js
Sencha Cmd v3.0.0.250
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[INF] Processing classPath entry : ext4/src
[INF] Processing classPath entry : ext4/examples/ux/grid
[INF] Processing classPath entry : util
[INF] Processing classPath entry : lib
[INF] Processing classPath entry : upc/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/util
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/ext4/examples/ux/grid
[INF] Processing class inheritance graph
[INF] Processing instantiation refereces to classes and aliases
[INF] Processing source dependencies
[ERR] Failed to find file for Ext.ux.grid.FiltersFeature.js
required by /home/steward/public_html/apps/MBH/upc/app/view/JobGrid.js
[ERR] Failed to find any files for Ext.ux.grid.FiltersFeature.js
steward$



I don't know what to ask. Please, any hint.

dongryphon
16 Dec 2012, 2:28 PM
Try running with the -debug switch:



sencha -debug compile ...


The output will be a lot larger, but hopefully there will be something of a clue in there about the mysteriously missing class.

dongryphon
16 Dec 2012, 2:30 PM
I would also recommend looking at MBH/upc/app/view/JobGrid.js to see how it references the class just in case there is a typo. Though it looks right from what I can tell.

stewardsencha
16 Dec 2012, 3:23 PM
Thanks for a reply.



requires: [
'Ext.ux.grid.FiltersFeature.js',
'Ext.ux.grid.menu/ListMenu.js',
'Ext.ux.grid.menu/RangeMenu.js',
'Ext.ux.grid.filter/BooleanFilter.js',
'Ext.ux.grid.filter/Filter.js',
'Ext.ux.grid.filter/DateFilter.js',
'Ext.ux.grid.filter/ListFilter.js',
'Ext.ux.grid.filter/NumericFilter.js',
'Ext.ux.grid.filter/StringFilter.js'
],

hankBook:MBH steward$ ./ccupc
Sencha Cmd v3.0.0.250
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[INF] Processing classPath entry : ext4/src
[INF] Processing classPath entry : ext4/examples/ux/grid
[INF] Processing classPath entry : util
[INF] Processing classPath entry : lib
[INF] Processing classPath entry : upc/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/util
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/ext4/examples/ux/grid
[INF] Processing class inheritance graph
[INF] Processing instantiation refereces to classes and aliases
[INF] Processing source dependencies
[INF] Compressing data with YuiJavascriptCompressor
[INF] Concatenating output to file build/upc/all-classes.js


That works but does not include the features (they all load at runtime).




requires:'Ext.ux.grid.*',

hankBook:MBH steward$ ./ccupc
Sencha Cmd v3.0.0.250
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[INF] Processing classPath entry : ext4/src
[INF] Processing classPath entry : ext4/examples/ux/grid
[INF] Processing classPath entry : util
[INF] Processing classPath entry : lib
[INF] Processing classPath entry : upc/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/util
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/ext4/examples/ux/grid
[INF] Processing class inheritance graph
[INF] Processing instantiation refereces to classes and aliases
[INF] Processing source dependencies
[ERR] Failed to find file for Ext.ux.grid.FiltersFeature.js
required by /home/steward/public_html/apps/MBH/upc/app/view/JobGrid.js
[ERR] com.sencha.exceptions.ExBuild: Failed to find any files for Ext.ux.grid.FiltersFeature.js
hankBook:MBH steward$



The debug:



Sencha Cmd v3.0.0.250
...
[DBG] found sencha.cfg at /Users/steward/bin/Sencha/Cmd/3.0.0.250
[DBG] found workspace at /home/steward/public_html/apps/MBH/.sencha/workspace
[DBG] Checking for framework config overrides
[DBG] Creating temporary directory /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[DBG] setting parse options
[DBG] loading class paths...
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[INF] Processing classPath entry : ext4/src
[INF] Processing classPath entry : ext4/examples/ux/grid
[INF] Processing classPath entry : util
[INF] Processing classPath entry : lib
[INF] Processing classPath entry : upc/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/app
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/util
[INF] Processing classPath entry : /home/steward/public_html/apps/MBH/ext4/examples/ux/grid
...
[DBG] Detected instantiation reference to Ext.util.MixedCollection in file /home/steward/public_html/apps/MBH/ext4/src/ux/grid/FiltersFeature.js
[DBG] [ [1001] : Class was referenced but not explicitly required <> Ext.util.MixedCollection ] :: ( /home/steward/public_html/ext-4.1.2a/src/ux/grid/FiltersFeature.js => 209 : 11 )
[DBG] Adding dynamic requirement on Ext.util.MixedCollection to FiltersFeature.js as a 'uses'
[DBG] Detected instantiation reference to Ext.util.Observable in file /home/steward/public_html/apps/MBH/ext4/src/ux/grid/FiltersFeature.js
[DBG] Detected Ext.create call
...
[DBG] Detected instantiation reference to Ext.util.MixedCollection in file /home/steward/public_html/apps/MBH/ext4/examples/ux/grid/FiltersFeature.js
[DBG] [ [1001] : Class was referenced but not explicitly required <> Ext.util.MixedCollection ] :: ( /home/steward/public_html/ext-4.1.2a/examples/ux/grid/FiltersFeature.js => 209 : 11 )
[DBG] Adding dynamic requirement on Ext.util.MixedCollection to FiltersFeature.js as a 'uses'
[DBG] Detected instantiation reference to Ext.util.Observable in file /home/steward/public_html/apps/MBH/ext4/examples/ux/grid/FiltersFeature.js
...
[DBG] Detected Ext.create call
[DBG] Detected instantiation reference to Ext.ux.grid.FiltersFeature in file /home/steward/public_html/apps/MBH/upc/app/view/JobGrid.js
[DBG] [ [1001] : Class was referenced but not explicitly required <> Ext.ux.grid.FiltersFeature ] :: ( /home/steward/public_html/apps/MBH/upc/app/view/JobGrid.js => 141 : 11 )
[DBG] Adding dynamic requirement on Ext.ux.grid.FiltersFeature to JobGrid.js as a 'uses'
...
[INF] Processing source dependencies
[DBG] processing 516 source files
...
[DBG] Processing dependencies for file: FiltersFeature.js
...
[DBG] Processing dependencies for file: FiltersFeature.js
...
[DBG] Processing dependencies for file: JobGrid.js
[ERR] Failed to find file for Ext.ux.grid.FiltersFeature.js
required by /home/steward/public_html/apps/MBH/upc/app/view/JobGrid.js
[DBG] com.sencha.exceptions.ExBuild
[DBG] removing tempdir /home/steward/public_html/apps/MBH/sencha-compile-temp-dir
[ERR] com.sencha.exceptions.ExBuild: Failed to find any files for Ext.ux.grid.FiltersFeature.js


Debug suggested I add



uses:'Ext.ux.grid.FiltersFeature.js',


but that seems to make no diff.

Don I am making some progress with cmd but it's very very slow and painful.
Meantime I need to produce something. Is there any way to "just do it"?
I will cheerfully create a hand-crafted list of what I want (there are so few at this time)
Do we have to go back to jsb3 files for that?

dongryphon
16 Dec 2012, 3:28 PM
You should specify "requires" and "uses" as class names not file names. Try this:



requires: [
'Ext.ux.grid.FiltersFeature',
'Ext.ux.grid.menu.ListMenu',
'Ext.ux.grid.menu.RangeMenu',
'Ext.ux.grid.filter.BooleanFilter',
'Ext.ux.grid.filter.Filter',
'Ext.ux.grid.filter.DateFilter',
'Ext.ux.grid.filter.ListFilter',
'Ext.ux.grid.filter.NumericFilter',
'Ext.ux.grid.filter.StringFilter'
],


This should also work:



requires: [
'Ext.ux.grid.FiltersFeature',
'Ext.ux.grid.menu.*',
'Ext.ux.grid.filter.*',
],

stewardsencha
16 Dec 2012, 4:16 PM
Crap.
Ok what I need is a lint utility that will find those particular no-see-ums.

Your last example is the cool way. I know that and I did that.
Then madness descended and it was cut to ribbons.
Sigh.

Thank you very much for your time and a helpful answer.

The other thing that killed me today was Ext.Direct
I think I grasp the issues, but I am failing to find my solution.
I think I would be happy if I could get three script tags:
ext-everythingness.js
remoting-readiness.js
app-all-classness.js

Hey. That looks like something maybe I can do. Stand by.