Getting Could not load type errors while publishing
Asked Answered
L

1

9

Getting following errors after trying to publish using aspnet_compiler

errorASPPARSE: Circular file references are not allowed.
errorASPPARSE: Unknown server tag 'uc2:FAQ'.
errorASPPARSE: Could not load type 'CompoundControls.BBar'.
errorASPPARSE: Could not load type 'CompoundControls.PPIndicator'.
errorASPPARSE: Unknown server tag 'm:Calendar'.
errorASPPARSE: Could not load type 'SharedUserControls.VCDetails'.
errorASPPARSE: Could not load type 'SharedUserControls.VPDetails'.
errorASPPARSE: Could not load type 'SharedUserControls.VPrDetails'.
errorASPPARSE: Could not load type '.PopupPaymentCardCCVHelp'.     

Any idea how to solve them

Lisabethlisan answered 20/5, 2009 at 15:2 Comment(1)
This is probably not related to CruiseControl.net : can you please invoke, from the command line, the same MSBuild command that CCNet is executing? You can see what it is trying to call in the build log, when the verbosity is set to DEBUG.Environs
C
1

There are several reasons why you would get Circular file references are not allowed error.

It is difficult to pin-point the exact cause without looking the project's structure or code.

However, if I were to take an educated guess, here's what I would do:

  • Looking at the next error: Unknown server tag 'uc2:FAQ'., it seems that it is not able to compile that user control.
  • It is also likely that this user control is the point of contention here. The rest being the result of UserControl not compiling.
  • If so, then check for any references to master page/any other page within the user control (something like <%@ Reference Control="~/app.master" %> within the ascx file).

Also, a not-so-obvious circular reference problem with user control happens when you unknowingly land into this situation (via batching):

PageA.aspx -> uc1.ascx -> PageB.aspx (batching) -> uc1.ascx -> PageA.aspx (batching)

If that is the likely cause, then try setting batch=false in your config:

<configuration>
  <system.web>
    <!-- should prevent errorASPPARSE: Circular file references are not allowed -->
    <compilation batch="false" />
  </system.web>
</configuration>

Hope this helps.

Curcuma answered 23/8, 2011 at 16:5 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.