Forums

Posting in these forums is disabled. These forums will be available for archive purposes. Please join the new forums at the links below:

  • yui-support - replaces the `YUI 3.x` and `YUI 3 Gallery` forums.
    We have created the following discussion categories within this group to aid discoverability for these most-used topics:
    • Charts for YUI Charts support.
    • DataTable for YUI DataTable support.
    • Gallery for YUI Gallery support, including support for published Gallery components as well as the Gallery process in general.
    • Tools for support of YUI’s suite of developer tools such as selleck, shifter, grover, yogi, etc.
    • Everything Else for questions that don’t fit one of the categories above, we’ve got you covered here.
  • yui-deprecated - replaces the `YUI 2.x` forum and the forums of other deprecated products (`YUI Doc`, `Builder`, `YUI PHP Loader`, etc.).
  [ 6 posts ]
New Topic | Post Reply | Print view
Previous topic | Next topic

Ben Delarre

YUI Contributor

  • Username: benjamind
  • Joined: Fri Sep 04, 2009 7:40 am
  • Posts: 8
  • GitHub: benjamind
  • Gists: benjamind
  • Offline
  • Profile
Tags:
  • builder
  • github
  • xml
  • yuicompressor

RuntimeException from YUICompressor with ant minify task

Post Posted: Fri Sep 09, 2011 2:14 am
Hi,

I'm just trying to put together my first module for the gallery. I've followed all the relevant guides and got my clone of the yui3-gallery repo locally. I've setup my modules folder structure to match those I've found on the gallery, and thought I was all ready to build.

But when I run 'ant all' from the src directory for my gallery it runs through most of the tasks then fails in the minify task with the following error:

Quote:
c:\Workspace\builder\componentbuild\shared\targets.xml:83: The following error occurred while executing this line:
c:\Workspace\builder\componentbuild\shared\macrolib.xml:92: java.lang.RuntimeException
at com.yahoo.platform.yui.compressor.JavaScriptCompressor.printSourceNumber(JavaScriptCompre
ssor.java:299)
...


I've delved into all this and added some additional logging to the targets.xml, and its clear that this exception is being thrown while compressing my JS. I've run my JS through JSLint and its perfectly clean with no errors or warnings at all (yes, that took me ages to sort out).

Does anyone have any suggestions about what I could be doing wrong? I've tried making my JS file completely empty, at which point we get a slightly different error a StringIndexOutOfBoundsException. This in itself seems pretty strange. I've also tried building with and without component.skinnable present in my build.properties, and both true and false values for it.

I've pulled the latest version of the builder off github, as well as the yui3-library project. I'm also running Java version 1.6.0_20 and ant version 1.8.1.

Any help would be appreciated.

Ben Delarre

YUI Contributor

  • Username: benjamind
  • Joined: Fri Sep 04, 2009 7:40 am
  • Posts: 8
  • GitHub: benjamind
  • Gists: benjamind
  • Offline
  • Profile
Tags:
  • github
  • yuicompressor

Re: RuntimeException from YUICompressor with ant minify task

Post Posted: Fri Sep 09, 2011 2:33 am
I forgot to include a link to the repository.

https://github.com/benjamind/yui3-gallery/tree/master/src/gallery-colorpicker

Hope somebody can help as I'd really like to get this colorpicker up finally.

Ben Delarre

YUI Contributor

  • Username: benjamind
  • Joined: Fri Sep 04, 2009 7:40 am
  • Posts: 8
  • GitHub: benjamind
  • Gists: benjamind
  • Offline
  • Profile
Tags:
  • yuicompressor

Re: RuntimeException from YUICompressor with ant minify task

Post Posted: Fri Sep 09, 2011 3:35 am
Further investigation has led me to believe there's something wrong with my environment. As I appear to not be able to do a 'ant all' on any of the gallery modules in the repository.

I am still however at a loss as to what I've done wrong.

Ben Delarre

YUI Contributor

  • Username: benjamind
  • Joined: Fri Sep 04, 2009 7:40 am
  • Posts: 8
  • GitHub: benjamind
  • Gists: benjamind
  • Offline
  • Profile

Re: RuntimeException from YUICompressor with ant minify task

Post Posted: Fri Sep 09, 2011 7:16 am
Turns out this is a bug in the latest version of builder in git. I grabbed the download of the 1.0.0b1 version and the build works fine.

I'll try and track down the bug and get a ticket filed sometime.

Timothy Heilig

  • Username: timheilig
  • Joined: Wed Sep 14, 2011 9:56 pm
  • Posts: 1
  • Offline
  • Profile
Tags:
  • yuicompressor

Re: RuntimeException from YUICompressor with ant minify task

Post Posted: Fri Jan 06, 2012 1:48 pm
I'm running into the same problem:


BUILD FAILED
builder/componentbuild/shared/targets.xml:82: The following error occurred while executing this line:
builder/componentbuild/shared/macrolib.xml:92: java.lang.ExceptionInInitializerError


What's odd is that it's intermittent. One time changing the module name fixed it, another time doing an ant clean fixed it. However it always seems to come back.

I'm running debian-lenny, java 1.5, ant 1.7 I wonder if it's configuration specific.

harold vera zamora

  • Username: haroldvera
  • Joined: Thu May 17, 2012 9:17 am
  • Posts: 1
  • Twitter: haroldvera
  • Offline
  • Profile
Tags:
  • yuicompressor

Re: RuntimeException from YUICompressor with ant minify task

Post Posted: Thu May 17, 2012 9:28 am
this problem is bothering me a few days ago. I resolved thanks to my friend luis sanchez impulseit.

The problem occurs because rt.jar has a different version of the class org.mozilla.javascript.Parse;

to solve the problem just type from ant project home,

export ANT_OPTS="-Xbootclasspath/p:./lib/yuicompressor-2.4.2.jar"

ant

enjoy!
  [ 6 posts ]
New Topic | Post Reply | Print view
Previous topic | Next topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum