FAForever / downlords-faf-client

Official client for Forged Alliance Forever
https://faforever.com
MIT License
196 stars 121 forks source link

Client throws exception on invalid characters in map names #614

Closed 1-alex98 closed 4 years ago

1-alex98 commented 7 years ago

java.util.concurrent.CompletionException: java.nio.file.InvalidPathException: Illegal char <?> at index 17: astro_crater_batl?_5vs5.v0002.png
    at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273) ~[na:1.8.0_111]
    at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280) ~[na:1.8.0_111]
    at java.util.concurrent.CompletableFuture.uniAccept(CompletableFuture.java:659) ~[na:1.8.0_111]
    at java.util.concurrent.CompletableFuture$UniAccept.tryFire(CompletableFuture.java:632) ~[na:1.8.0_111]
    at java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474) ~[na:1.8.0_111]
    at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1595) ~[na:1.8.0_111]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_111]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[na:1.8.0_111]
    at java.lang.Thread.run(Thread.java:745) ~[na:1.8.0_111]
Caused by: java.nio.file.InvalidPathException: Illegal char <?> at index 17: astro_crater_batl?_5vs5.v0002.png
    at sun.nio.fs.WindowsPathParser.normalize(WindowsPathParser.java:182) ~[na:1.8.0_111]
    at sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:153) ~[na:1.8.0_111]
    at sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:77) ~[na:1.8.0_111]
    at sun.nio.fs.WindowsPath.parse(WindowsPath.java:94) ~[na:1.8.0_111]
    at sun.nio.fs.WindowsFileSystem.getPath(WindowsFileSystem.java:255) ~[na:1.8.0_111]
    at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) ~[na:1.8.0_111]
    at com.faforever.client.remote.AssetServiceImpl.loadAndCacheImage(AssetServiceImpl.java:51) ~[classes/:na]
    at com.faforever.client.remote.AssetServiceImpl.loadAndCacheImage(AssetServiceImpl.java:37) ~[classes/:na]
    at com.faforever.client.map.MapServiceImpl.loadPreview(MapServiceImpl.java:327) ~[classes/:na]
    at com.faforever.client.map.MapServiceImpl.loadPreview(MapServiceImpl.java:323) ~[classes/:na]
    at sun.reflect.GeneratedMethodAccessor123.invoke(Unknown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_111]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_111]
    at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheInterceptor$1.invoke(CacheInterceptor.java:52) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.invokeOperation(CacheAspectSupport.java:345) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:408) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:327) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheInterceptor.invoke(CacheInterceptor.java:61) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at com.sun.proxy.$Proxy75.loadPreview(Unknown Source) ~[na:na]
    at com.faforever.client.map.MapCardController.setMap(MapCardController.java:79) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.lambda$appendSearchResult$13(MapVaultController.java:272) ~[classes/:na]
    at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) ~[na:1.8.0_111]
    at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1374) ~[na:1.8.0_111]
    at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481) ~[na:1.8.0_111]
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) ~[na:1.8.0_111]
    at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:747) ~[na:1.8.0_111]
    at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:721) ~[na:1.8.0_111]
    at java.util.stream.AbstractTask.compute(AbstractTask.java:316) ~[na:1.8.0_111]
    at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinPool$WorkQueue.pollAndExecCC(ForkJoinPool.java:1190) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinPool.helpComplete(ForkJoinPool.java:1879) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinPool.externalHelpComplete(ForkJoinPool.java:2467) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinTask.externalAwaitDone(ForkJoinTask.java:324) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinTask.doInvoke(ForkJoinTask.java:405) ~[na:1.8.0_111]
    at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:734) ~[na:1.8.0_111]
    at java.util.stream.ReduceOps$ReduceOp.evaluateParallel(ReduceOps.java:714) ~[na:1.8.0_111]
    at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233) ~[na:1.8.0_111]
    at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499) ~[na:1.8.0_111]
    at com.faforever.client.map.MapVaultController.appendSearchResult(MapVaultController.java:275) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.replaceSearchResult(MapVaultController.java:159) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.lambda$displayShowroomMaps$5(MapVaultController.java:149) ~[classes/:na]
    at java.util.concurrent.CompletableFuture.uniAccept(CompletableFuture.java:656) ~[na:1.8.0_111]
    ... 6 common frames omitted```
micheljung commented 7 years ago

? is an invalid character on Windows systems, in astro_crater_batl?_5vs5.v0002.png

1-alex98 commented 6 years ago

The same goes for

java.util.concurrent.CompletionException: java.nio.file.InvalidPathException: Illegal char <    > at index 16: yerros_mountains     .v0002.png
    at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273) ~[na:1.8.0_152]
    at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280) ~[na:1.8.0_152]
    at java.util.concurrent.CompletableFuture.uniAccept(CompletableFuture.java:659) ~[na:1.8.0_152]
    at java.util.concurrent.CompletableFuture$UniAccept.tryFire(CompletableFuture.java:632) ~[na:1.8.0_152]
    at java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474) ~[na:1.8.0_152]
    at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1595) ~[na:1.8.0_152]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_152]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_152]
    at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_152]
Caused by: java.nio.file.InvalidPathException: Illegal char <   > at index 16: yerros_mountains     .v0002.png
    at sun.nio.fs.WindowsPathParser.normalize(WindowsPathParser.java:182) ~[na:1.8.0_152]
    at sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:153) ~[na:1.8.0_152]
    at sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:77) ~[na:1.8.0_152]
    at sun.nio.fs.WindowsPath.parse(WindowsPath.java:94) ~[na:1.8.0_152]
    at sun.nio.fs.WindowsFileSystem.getPath(WindowsFileSystem.java:255) ~[na:1.8.0_152]
    at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) ~[na:1.8.0_152]
    at com.faforever.client.remote.AssetServiceImpl.loadAndCacheImage(AssetServiceImpl.java:51) ~[classes/:na]
    at com.faforever.client.remote.AssetServiceImpl.loadAndCacheImage(AssetServiceImpl.java:37) ~[classes/:na]
    at com.faforever.client.map.MapServiceImpl.loadPreview(MapServiceImpl.java:331) ~[classes/:na]
    at com.faforever.client.map.MapServiceImpl.loadPreview(MapServiceImpl.java:327) ~[classes/:na]
    at sun.reflect.GeneratedMethodAccessor135.invoke(Unknown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152]
    at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheInterceptor$1.invoke(CacheInterceptor.java:52) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.invokeOperation(CacheAspectSupport.java:345) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:408) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:327) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.cache.interceptor.CacheInterceptor.invoke(CacheInterceptor.java:61) ~[spring-context-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213) ~[spring-aop-4.3.6.RELEASE.jar:4.3.6.RELEASE]
    at com.sun.proxy.$Proxy75.loadPreview(Unknown Source) ~[na:na]
    at com.faforever.client.map.MapCardController.setMap(MapCardController.java:79) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.lambda$appendSearchResult$16(MapVaultController.java:287) ~[classes/:na]
    at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) ~[na:1.8.0_152]
    at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1382) ~[na:1.8.0_152]
    at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481) ~[na:1.8.0_152]
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) ~[na:1.8.0_152]
    at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:747) ~[na:1.8.0_152]
    at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:721) ~[na:1.8.0_152]
    at java.util.stream.AbstractTask.compute(AbstractTask.java:316) ~[na:1.8.0_152]
    at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731) ~[na:1.8.0_152]
    at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[na:1.8.0_152]
    at java.util.concurrent.ForkJoinTask.doInvoke(ForkJoinTask.java:401) ~[na:1.8.0_152]
    at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:734) ~[na:1.8.0_152]
    at java.util.stream.ReduceOps$ReduceOp.evaluateParallel(ReduceOps.java:714) ~[na:1.8.0_152]
    at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233) ~[na:1.8.0_152]
    at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499) ~[na:1.8.0_152]
    at com.faforever.client.map.MapVaultController.appendSearchResult(MapVaultController.java:290) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.replaceSearchResult(MapVaultController.java:169) ~[classes/:na]
    at com.faforever.client.map.MapVaultController.lambda$displayShowroomMaps$5(MapVaultController.java:158) ~[classes/:na]
    at java.util.concurrent.CompletableFuture.uniAccept(CompletableFuture.java:656) ~[na:1.8.0_152]
    ... 6 common frames omitted
1-alex98 commented 6 years ago

Because of this map vault is party broken

1-alex98 commented 6 years ago

Funny thing is the picture is there and called: "yerros_mountains.v0005.png"

1-alex98 commented 6 years ago

The filename is derived from the download url and in this case this is : http://content.faforever.com/maps/previews/small/yerros_mountains\t\t.v0002.png

1-alex98 commented 4 years ago

The third time I am reading this now duplicate