changcheng / wro4j

Automatically exported from code.google.com/p/wro4j
0 stars 0 forks source link

Run-time SASS pre-processor causes 404 #522

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using 1.4.8 run-time implementation.
Linux (64-bit), Java 1.7.0_05

wro.properties file

    debug=true
    gzipEnabled=true
    jmxEnabled=true
    mbeanName=wro
    cacheUpdatePeriod=0
    modelUpdatePeriod=0
    disableCache=true
    encoding=UTF-8
    parallelPreprocessing=true
    resourceWatcherUpdatePeriod=5
    managerFactoryClassName=ro.isdc.wro.manager.factory.ConfigurableWroManagerFactory
    preProcessors=rubySassCss
    postProcessors=cssMinJawr

web.xml

  <filter>
    <filter-name>WebResourceOptimizer</filter-name>
    <filter-class>ro.isdc.wro.http.WroFilter</filter-class>
  </filter>
  <filter-mapping>
    <filter-name>WebResourceOptimizer</filter-name>
    <url-pattern>/wro/*</url-pattern>
  </filter-mapping>

Model example

    <group name="buttons">
        <css>/css/font-awesome.css</css>
        <css>/css/buttons.scss</css>
    </group>

When requesting /wro/buttons.css, I receive a 404 response (same for all other 
groups). Removing the `rubySassCss` pre-processor, everything works (except 
SASS files aren't parsed).

Running the maven build task works fine, SASS files are parsed correctly and 
the generated output is perfect.

Original issue reported on code.google.com by gnoodl on 13 Aug 2012 at 5:50

GoogleCodeExporter commented 9 years ago
Forgot to mention, the same thing happens when using the `sassCss` processor

Original comment by gnoodl on 13 Aug 2012 at 5:51

GoogleCodeExporter commented 9 years ago
There are no errors produced. I have log4j configured with

    log4j.logger.ro.isdc.wro=DEBUG

Original comment by gnoodl on 13 Aug 2012 at 5:51

GoogleCodeExporter commented 9 years ago
Can you attach the resources from your model?

Original comment by alex.obj...@gmail.com on 13 Aug 2012 at 7:00

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago

Original comment by alex.obj...@gmail.com on 13 Aug 2012 at 7:22

GoogleCodeExporter commented 9 years ago
Cannot reproduce the problem. 
When requesting the following resource: http://localhost:8080/wro/buttons.css I 
get a valid css response.

You can check it yourself by checkout the branch called issue522 (on github) 
and run the wro4j-demo project located in wro4j-examples folder. 

Let me know if you have more details.

PS: Btw, try the version 1.4.8.1 (which shouldn't make any difference for this 
issue, but it is still the newest released version).

Original comment by alex.obj...@gmail.com on 13 Aug 2012 at 7:37

GoogleCodeExporter commented 9 years ago
I got your demo working too. Must be something else in my app / environment.

I'll keep checking and report back any findings. Thanks for your help Alex

Original comment by gnoodl on 14 Aug 2012 at 4:12

GoogleCodeExporter commented 9 years ago
Due to the way the context with wro4j was being run, we had excluded 
wro4j-extensions. All fixed now, thanks for your time Alex

Original comment by gnoodl on 14 Aug 2012 at 5:37

GoogleCodeExporter commented 9 years ago
I don't really understand what was the problem. Could you explain it in
more details?

Original comment by alex.obj...@gmail.com on 14 Aug 2012 at 6:03

GoogleCodeExporter commented 9 years ago
Marking the issue as invalid. 
Feel free to reopen if there are more details available...

Original comment by alex.obj...@gmail.com on 14 Aug 2012 at 11:42