Log of the #nice channel on irc.freenode.net

Using timezone: Central European Time
* arjanb leaves00:57
* bonniot leaves07:49
* bonniot joins09:10
* arjanb joins09:52
* arjanb will be away for a day or two12:59
* arjanb leaves
* ArtemGr joins14:14
<CIA-3>03bonniot * 10Nice/src/bossa/modules/ (4 files): 14:38
Fix archive creation so that the most recent version of each class file is
included in it (regenerated has priority over any previous version).
* Artem joins15:18
* ArtemGr leaves
* raboof leaves15:26
<ArtemGr>i've checked the new testing engine. it's tidy, but lacks a lot of features of the existing test engine. the question is, whether you plan to integrate the two?15:30
<bonniot>not in the short term15:31
it was urgent so we can express all testcases
the current version is indeed preliminary, the design will evolve with usage15:32
i think for now we should focus on making it support well those tests that don't fit yet15:33
how does that sound?
<ArtemGr>okay. i'm thinking about implementing java compilation. i think it is good enough to control the testing engine thru java properties (System.getProperty) - we can convert system environments to java properties using ant / makefile.15:35
i've asked how ant calls javac so it works on most systems
first it tried to find tools.jar in JAVA_HOME (java.home?) if it's not there, it looks for a javac binary on the path15:37
i've created a small SelfContainedClassLoader class that does not delegate to its parent (except for java* classes)15:39
it works here, but I know you said you got problems with that situation. you know in what conditions?
<ArtemGr>i wonder, what portatibility problems did you expect? program execution is implemented portable enough in Java.
about class-loading - did you try to load the class in the parent classloader, and then it's modified version in the SelfContained one?15:40
<bonniot>yes, but as soon as you try to look up files on the filesystem, they might be there, or not (tools.jar for instance)
<ArtemGr>without javac on the PATH the Nice will not be compiled, so i see no problems invoking it from the testsuite.15:42
<bonniot>me neither15:43
ant used to only look for tools.jar, that was the problem
classloading: what i'm trying to do is to isolate the jar just generated when running it15:44
and it works
<ArtemGr>ant: that's probably if the fork option is set to no, then it tries to optimize by using javac in the same VM
<ArtemGr>classloading: sure it works, if you load the class for the first time. the problem is when the modified class is loaded for the second time. it can't. i've described the situation before. there is a Context, which is used by the application. application then compiles the template, which have a modified Context (becouse of methods with Context being the first argument of) - this compiled template i15:47
s then loaded and surely it uses the old version of the Context.
<bonniot>i think this is a different issue15:48
i'm speaking about a security exception you got
<ArtemGr>why do you think this is a different issu, if the exception i got was exactly for that Context class?15:49
<bonniot>the way i understood it, in one case the jvm was failing with a security exception, in another it was the "wrong" version of a class being used15:50
<ArtemGr>clarification: by default the "wrong" version of the class is used, becouse parent classloader is asked for the class, and it already contains it. if i try to mitigate the problem by forsing the classloader to load everything from itself first, then it can't, presumably becouse the class is already loaded and _used_.15:52
<bonniot>how does "it can't" manifest itself?15:53
"java.lang.LinkageError: Class ru/promo/m/cms/Workspace violates loader constraints" ?
it will be interesting to see a testcase, but I think this means that my change for running the jar is OK
i'll commit it
let me know if there is any problem15:57
<CIA-3>03bonniot * 10Nice/ (2 files in 2 dirs):
Run generated jars in a self-contained classloader, so that missing classes in the jar lead to errors, instead of being loaded from the parent.
Use "classes" instead of nice.jar so that recent changes immediately affect testcases.
Rethrow the cause exception when a testcase fails.
<ArtemGr> [java] C:\spool\Java\rebuild\Nice\testsuite\helpers.nice: line 95, column 20:17:04
[java] nice.tools.util.SelfContainedClassLoader is not declared
<bonniot>you need to compile it ;-)17:05
<ArtemGr>ah, it's not that, i somehow had checked out only a part of recent changes.17:06
<CIA-3>03artemgr * 10Nice/src/nice/tools/testsuite/runner.nice: Keep root directory clean: compile into temporary folder.17:54
03artemgr * 10Nice/build.xml: New test engine integrated.
<bonniot>do you have ideas about naming conventions for the tests? do you have some tests already?19:26
* ArtemGr leaves19:32

Generated by Sualtam