Community
Participate
Working Groups
On Mac OSX .DS_Store files are created when visiting directories with the Finder. When this happens in the features directory, Tycho tries to open that file as JarFile, which fails with a ZipException. The error should be ignored when the file does not have the .jar file extension. [ERROR] Internal error: java.lang.RuntimeException: Could not read feature descriptor at /Users/thoms/Development/Eclipse/eclipse-3.7/features/.DS_Store: error in opening zip file -> [Help 1] org.apache.maven.InternalErrorException: Internal error: java.lang.RuntimeException: Could not read feature descriptor at /Users/thoms/Development/Eclipse/eclipse-3.7/features/.DS_Store at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:168) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:534) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352) Caused by: java.lang.RuntimeException: Could not read feature descriptor at /Users/thoms/Development/Eclipse/eclipse-3.7/features/.DS_Store at org.eclipse.tycho.model.Feature.loadFeature(Feature.java:202) at org.eclipse.tycho.core.osgitools.targetplatform.LocalTargetPlatformResolver.resolvePlatform(LocalTargetPlatformResolver.java:110) at org.eclipse.tycho.core.resolver.DefaultTychoDependencyResolver.resolveProject(DefaultTychoDependencyResolver.java:90) at org.eclipse.tycho.core.maven.TychoMavenLifecycleParticipant.afterProjectsRead(TychoMavenLifecycleParticipant.java:91) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:273) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) ... 11 more Caused by: java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.<init>(ZipFile.java:127) at java.util.jar.JarFile.<init>(JarFile.java:135) at java.util.jar.JarFile.<init>(JarFile.java:99) at org.eclipse.tycho.model.Feature.readJar(Feature.java:172) at org.eclipse.tycho.model.Feature.loadFeature(Feature.java:198) ... 16 more
Does this issue still occur with 0.13.0-SNAPSHOT?
originally reported as https://issues.sonatype.org/browse/TYCHO-387
Still occurs in 0.13.0-SNAPSHOT. I built from the sources. Thread [main] (Suspended (exception ZipException)) ZipFile.open(String, int, long, boolean) line: not available [native method] JarFile(ZipFile).<init>(File, int) line: 127 JarFile.<init>(File, boolean, int) line: 135 JarFile.<init>(File) line: 99 Feature.readJar(File) line: 172 Feature.loadFeature(File) line: 198 LocalTargetPlatformResolver.resolvePlatform(MavenSession, MavenProject, List<ReactorProject>, List<Dependency>) line: 110 DefaultTychoDependencyResolver.resolveProject(MavenSession, MavenProject, List<ReactorProject>) line: 90 TychoMavenLifecycleParticipant.afterProjectsRead(MavenSession) line: 91 DefaultMaven.doExecute(MavenExecutionRequest) line: 273 DefaultMaven.execute(MavenExecutionRequest) line: 156 MavenCli.execute(MavenCli$CliRequest) line: 534 MavenCli.doMain(MavenCli$CliRequest) line: 196 MavenCli.main(String[], ClassWorld) line: 141 NativeMethodAccessorImpl.invoke0(Method, Object, Object[]) line: not available [native method] NativeMethodAccessorImpl.invoke(Object, Object[]) line: 39 DelegatingMethodAccessorImpl.invoke(Object, Object[]) line: 25 Method.invoke(Object, Object...) line: 597 Launcher.launchEnhanced(String[]) line: 290 Launcher.launch(String[]) line: 230 Launcher.mainWithExitCode(String[]) line: 409 Launcher.main(String[]) line: 352
(In reply to comment #3) > Still occurs in 0.13.0-SNAPSHOT. I built from the sources. So it was only discussed, but unfortunately not yet solved. Thanks for verifying this. Btw. you can also get 0.13.0-SNAPSHOT from Tycho's CI build (see http://www.eclipse.org/tycho/download.php )
Created attachment 202674 [details] proposed patch (filter files in the featurs directory) Uses a FileFilter which filters out dot files and accepts only jar files and directories in the feature folder as candidates for features.
Applied patch in master (b363c9e). Thank you Holger!