[ome-devel] cellh5 reader for bio-formats

Christoph Sommer christoph.sommer at imba.oeaw.ac.at
Thu Apr 25 14:33:45 BST 2013


Dear Melissa,

thanks for the fast reply!
> The develop branch of https://github.com/openmicroscopy/bioformats 
> should compile and pass all tests. What sort of development 
> environment are you using? How are you compiling and running tests?
>> What HDF5 library for Java would you recommend for native hdf5
>> access? To write these files (currently from Python) I we HDF5 1.8.7
I am new to Java and Maven so I followed instructions from 
http://loci.wisc.edu/bio-formats/developing-bio-formats. Using Eclipse 
(3.7 Indigo) I am unable to run the tests. I guess I haven't set up the 
project properly... I attached the output I get in the eclipse console 
running "maven build" (eclipse_build_output.txt). Somehow Eclipse cannot 
resolve "import loci.formats.meta.MetadataStore;"

Running Maven from the command line executes the tests and it looks 
promising. Only 4 test in SCIFIO fail. I attached the surefire html 
report... here's the console output.

> -------------------------------------------------------
>  T E S T S
> -------------------------------------------------------
> Running TestSuite
> [Parser] [WARN] Unknown value of attribute 'parallel' at suite level: 
> '@PARALLEL@'.
> Tests run: 954, Failures: 4, Errors: 0, Skipped: 0, Time elapsed: 
> 1,302.851 sec <<< FAILURE!
>
> Results :
>
> Failed tests: testIsDirectory(ome.scifio.io.utests.LocationTest): 
> bio-formats expected:<true> but was:<false>
>   testIsFile(ome.scifio.io.utests.LocationTest): bio-formats 
> expected:<false> but was:<true>
>   testIsHidden(ome.scifio.io.utests.LocationTest): 
> .hiddenTest1218465869181829460.tmp expected:<false> but was:<true>
>   testToURL(ome.scifio.io.utests.LocationTest): 
> validTest5911385117004500129.tmp 
> expected:<file:/C:/Users/sommerc/AppData/Local/Temp/1366896587552-locat
> est5911385117004500129.tmp> but 
> was:<file://C:/Users/sommerc/AppData/Local/Temp/1366896587552-location-test/validTest5911385117004500129.tmp>
>
> Tests run: 954, Failures: 4, Errors: 0, Skipped: 0
>
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] Reactor Summary:
> [INFO]
> [INFO] Bio-Formats projects .............................. SUCCESS 
> [1.413s]
> [INFO] JAI Image I/O Tools ............................... SUCCESS 
> [1.720s]
> [INFO] MDB Tools (Java port) ............................. SUCCESS 
> [0.450s]
> [INFO] SCIFIO-devel ...................................... FAILURE 
> [21:43.630s]
> [INFO] Loci-Legacy ....................................... SKIPPED
> [INFO] Apache Jakarta POI ................................ SKIPPED
> [INFO] Luratech LuraWave stubs ........................... SKIPPED
> [INFO] OME-XML Java library .............................. SKIPPED
> [INFO] libjpeg-turbo Java bindings ....................... SKIPPED
> [INFO] SCIFIO ............................................ SKIPPED
> [INFO] Bio-Formats code generator ........................ SKIPPED
> [INFO] Metakit ........................................... SKIPPED
> [INFO] Bio-Formats library ............................... SKIPPED
> [INFO] LOCI Common compatibility JAR ..................... SKIPPED
> [INFO] LOCI Plugins for ImageJ ........................... SKIPPED
> [INFO] LOCI Tools bundle ................................. SKIPPED
> [INFO] OME I/O ........................................... SKIPPED
> [INFO] OME Plugins for ImageJ ............................ SKIPPED
> [INFO] OME Tools bundle .................................. SKIPPED
> [INFO] SCIFIO ............................................ SKIPPED
> [INFO] LOCI testing framework ............................ SKIPPED
> [INFO] XSD-FU ............................................ SKIPPED
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] BUILD FAILURE
> [INFO] 
> ------------------------------------------------------------------------
> [INFO] Total time: 21:48.070s
> [INFO] Finished at: Thu Apr 25 15:29:48 CEST 2013
> [INFO] Final Memory: 22M/440M
> [INFO] 
> ------------------------------------------------------------------------
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.12:test 
> (default-test) on project scifio-devel: There are
> [...]
>
Btw. Where is the correct place to put a unit test case for the new 
reader class?

Cheers,
Christoph

-------------- next part --------------
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building Bio-Formats library 4.5-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- imagej-maven-plugin:0.1.0:set-rootdir (set-rootdir) @ bio-formats ---
[INFO] Setting rootdir: C:\Users\sommerc\src\bioformats
[INFO] 
[INFO] --- buildnumber-maven-plugin:1.1:create (default) @ bio-formats ---
[INFO] Checking for local modifications: skipped.
[INFO] Updating project files from SCM: skipped.
[INFO] Executing: cmd.exe /X /C "git rev-parse --verify HEAD"
[INFO] Working directory: C:\Users\sommerc\src\bioformats\components\bio-formats
[INFO] Storing buildNumber: 40308c25bb7e607bc4b37167a81930bb217b180a at timestamp: 1366895086490
[INFO] Executing: cmd.exe /X /C "git rev-parse --verify HEAD"
[INFO] Working directory: C:\Users\sommerc\src\bioformats\components\bio-formats
[INFO] Storing buildScmBranch: UNKNOWN
[INFO] 
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) @ bio-formats ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 3 resources
[INFO] skip non existing resourceDirectory C:\Users\sommerc\src\bioformats\components\bio-formats\lib
[INFO] 
[INFO] --- maven-compiler-plugin:2.5:compile (default-compile) @ bio-formats ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-resources-plugin:2.5:testResources (default-testResources) @ bio-formats ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 17 resources
[INFO] 
[INFO] --- maven-compiler-plugin:2.5:testCompile (default-testCompile) @ bio-formats ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-surefire-plugin:2.12:test (default-test) @ bio-formats ---
[INFO] Surefire report directory: C:\Users\sommerc\src\bioformats\components\bio-formats\target\surefire-reports

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running TestSuite
org.apache.maven.surefire.util.SurefireReflectionException: java.lang.reflect.InvocationTargetException; nested exception is java.lang.reflect.InvocationTargetException: null
java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
	at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
	at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:103)
	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:74)
Caused by: org.testng.TestNGException: 
Cannot instantiate class loci.formats.utests.xml.Upgrade200809Test
	at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:35)
	at org.testng.internal.ClassHelper.createInstance(ClassHelper.java:317)
	at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:71)
	at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:90)
	at org.testng.internal.TestNGClassFinder.<init>(TestNGClassFinder.java:119)
	at org.testng.TestRunner.initMethods(TestRunner.java:379)
	at org.testng.TestRunner.init(TestRunner.java:254)
	at org.testng.TestRunner.init(TestRunner.java:224)
	at org.testng.TestRunner.<init>(TestRunner.java:173)
	at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:494)
	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:239)
	at org.testng.SuiteRunner.run(SuiteRunner.java:193)
	at org.testng.TestNG.createAndRunSuiteRunners(TestNG.java:910)
	at org.testng.TestNG.runSuitesLocally(TestNG.java:879)
	at org.testng.TestNG.run(TestNG.java:787)
	at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:177)
	at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:92)
	at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:105)
	... 9 more
Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
	at java.lang.reflect.Constructor.newInstance(Unknown Source)
	at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:26)
	... 26 more
Caused by: java.lang.Error: Unresolved compilation problems: 
	The import ome.xml.model.Image cannot be resolved
	The import ome.xml.model.OME cannot be resolved
	The import ome.xml.model.Pixels cannot be resolved
	OME cannot be resolved to a type
	OME cannot be resolved to a type
	OME cannot be resolved to a type
	The method getRoot() is undefined for the type OMEXMLMetadata
	OME cannot be resolved to a type
	Image cannot be resolved to a type
	OME cannot be resolved to a type
	Pixels cannot be resolved to a type
	The method getChannelColor(int, int) is undefined for the type OMEXMLMetadata
	at loci.formats.utests.xml.Upgrade200809Test.<init>(Upgrade200809Test.java:38)
	... 31 more

Results :

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.719s
[INFO] Finished at: Thu Apr 25 15:04:48 CEST 2013
[INFO] Final Memory: 9M/243M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project bio-formats: Error occurred in starting fork, check output in log -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20130425/7d7d5e9f/attachment-0001.html>


More information about the ome-devel mailing list