Uploaded image for project: 'Commons Sandbox'
  1. Commons Sandbox
  2. SANDBOX-290

[javaflow] Ant task terminates with org.apache.bcel.verifier.exc.AssertionViolatedException

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Javaflow
    • Labels:
      None

      Description

      Unexpected behaviour: When the Javaflow Ant task is executed on a set of class files in the file system, then Ant terminates with the error message:

      C:\svnx\dev_scream\build.xml:155: org.apache.bcel.verifier.exc.AssertionViolatedException: INTERNAL ERROR: Missing class: java.lang.ClassNotFoundException: Exception while looking for class de.michab.scream.FirstClassObject: java.io.IOException: Couldn't find: de/michab/scream/FirstClassObject.class

      Expected is, that the task can rewrite the class files without throwing an exception.

      The reason for the above behaviour is that currently no explicit Bcel repository is set. This repository (org.apache.bcel.util.Repository) is responsible for resolving class references while Bcel is working. Since none was set explicitly, the implicit default repository is used, which depends on the class path.

      The solution for the above problem is that the BcelClassTransformer always explicitly installs a SyntheticRepository that points to the task's srcDir.

        Attachments

        1. BcelClassTransformer.java
          40 kB
          Michael Binz
        2. AntRewriteTask.java
          6 kB
          Michael Binz

          Activity

            People

            • Assignee:
              tcurdt Torsten Curdt
              Reporter:
              michab66 Michael Binz

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment