PDA

View Full Version : Failed sencha compile - Error - Circular requires reference



RamalingamS
9 Dec 2012, 12:37 AM
Our index.jsp is this


<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/ext-4.1.1a/resources/css/ext-all-gray.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/resources/css/COP.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/resources/css/tabpanelcss.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/resources/css/topGrid.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/resources/css/userProfile.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/resources/css/topboilerplate.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/ext-4.1.1a/ux/form/field/BoxSelect.css" media="all">
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/ext-4.1.1a/ux/css/CheckHeader.css" media="all"/>
<script type="text/javascript">
var DEFAULT_VERSION_NO=<%=request.getParameter("versionNumber")%>;
var DEFAULT_ID=<%=request.getParameter("Id")%>;
</script>

<script type="text/javascript" src="<%=request.getContextPath() %>/ext-4.1/ext-all-debug.js"></script>

<script type="text/javascript" src="<%= request.getContextPath() %>/appConstants.jsp"></script>
<script type="text/javascript" src="<%=request.getContextPath() %>/app.js"></script>
<script type="text/javascript" src="<%= request.getContextPath() %>/all-classes.js"></script>

</head>
...


When we use the Sencha Command


sencha compile -classpath=ext-4.1/,app \ page -name=page -in index.jsp -out build/index.jsp and \ restore page and \ concat -yui all-classes.js


The Error pops up as


[ERR] Circular requires reference :
/ext-4.1.1.a/ext-all.js ->
/WebContent/ext-4.1/src/core/src/dom/CompositeElement.js ->
/WebContent/ext-4.1/src/core/src/dom/CompositeElementLite.js ->
/WebContent/ext-4.1/ext-all.js
[ERR] com.sencha.exceptions.ExCircularReference: Circular requires reference for file /WebContent/ext-4.1/ext-all.js


Any Support to overcome would be greatly appreciated.

RamalingamS
10 Dec 2012, 6:02 AM
Tried to use an Application generated by Sencha generate & replaced with our application for the files
This when we try to compile it we have a circular reference within the same file


Circular requires reference :
/CMDWS/APP/app/app.js ->
/CMDWS/APP/app/controller/SegmentDetail.js ->
/CMDWS/APP/app/view/landing/segment/EmailReportWin.js ->
/CMDWS/APP/ext/src/ux/form/field/BoxSelect.js ->
/CMDWS/APP/ext/src/ux/form/field/BoxSelect.js
[ERR] BUILD FAILED


Any way to overcome the circular references would be greatly appreciated.

RamalingamS
10 Dec 2012, 6:18 AM
Confirmed Solution.
Separating the 2 declarations into files works.
Make sure you put the BoxSelectField before BoxSelect.

Already solved & available at
https://github.com/kveeiv/extjs-boxselect/issues/22