perwendel / spark

A simple expressive web framework for java. Spark has a kotlin DSL https://github.com/perwendel/spark-kotlin
Apache License 2.0
9.64k stars 1.56k forks source link

Problem serving font files via staticFileLocation #943

Closed tssk closed 5 years ago

tssk commented 6 years ago

I had a problem serving font files via staticFileLocation. But serving JS or CSS files worked ok. For font files I got error like:

The requested route [/fonts] has not been mapped in Spark for Accept: [application/font-woff2;q=1.0,application/font-woff;q=0.9,/;q=0.8]

I found this issue https://github.com/perwendel/spark/issues/345 and downgraded to spark-core version 2.5.4 (which also downgraded jetty) and it started to work ok.

Strangely after upgrading back to spark-core version 2.7.0 (to reproduce the error) it is working ok now.

I am not sure if there is something to solve but I wanted to note this down in case someone gets the same error.

Tomas