Discussion:
[jruby-user] File to import not found or unreadable: compass/reset, Why?
Guofeng Zhang
2014-08-22 07:09:37 UTC
Permalink
Hi,

I following the following link to create single runnable jar containing
sass, compass, and jruby:
http://seanchenxi.com/java/sass-compass-jruby-single-jar/
then I use:
java -jar jcompass.jar -S compass create MY_JPROJECT
to create a project. I got the following error message:
error MY_JPROJECT/sass/screen.scss (Line 6: File to import not found or
unre
adable: compass/reset.
Load paths:
Compass::SpriteImporter
C:/projects/f5/jsass/MY_JPROJECT/sass

file:C:/projects/f5/jsass/jcompass.jar!/gems/compass-core-1.0.1/stylesheets)
Compilation failed in 1 files.

I don't know what happened for this error. I check that compass/_reset.scss
exsited in the directory "gems\compass-core-1.0.1\stylesheets" in
jcompass.jar.

How to solve it?

I use JDK jdk1.8.0_11 on Windows 8.

Thanks for your help?

Guofeng
christian
2014-08-22 08:07:53 UTC
Permalink
for some reason it does not look into the jar for finding that this file.

could you try to add the following load_path:

java -jar jcompass.jar -I classpath:/ -S compass create MY_JPROJECT

would be interesting to know since there is refactoring going on regarding
loading of such resources.
Guofeng Zhang
2014-08-22 08:54:13 UTC
Permalink
Use the command line you given, I got the same error, that
is, compass/reset still cannot be found or unreadable.

Thanks for your quick reply.
Post by christian
for some reason it does not look into the jar for finding that this file.
java -jar jcompass.jar -I classpath:/ -S compass create MY_JPROJECT
would be interesting to know since there is refactoring going on regarding
loading of such resources.
christian
2014-08-22 09:37:30 UTC
Permalink
hoops did not see this:

file:C:/projects/f5/jsass/jcompass.jar!/gems/compass-core-1.0.1/stylesheets

and with this it should actually work - i.e. it look like a bug with the
windows absolute path and resources from within a jar !

so my "trick" needs a modification then

java -jar jcompass.jar -I classpath:/gems/compass-core-1.0.1/stylesheets
-S compass create MY_JPROJECT

but I admit it would be crude workaround (in case it really works).
Guofeng Zhang
2014-08-23 17:26:46 UTC
Permalink
This issue is solved by rolling back to Compass 0.12.7 and SASS 3.2.9. see
http://foundation.zurb.com/forum/posts/18630-scss-compiles-but-resulting-css-file-incomplete.
The last version of compass might have issues.

I really want to use Foundation with Compass, so I use ruby (not jruby) to
taste its sample and find that the compiled css file is very small and the
page is not styled. then I found the above link.

After rolled back,
java -jar jcompass.jar -S compass create MY_JPROJECT
or
java -jar jcompass.jar -S compass compile
worked well.

Thanks for your time very much.
Post by Guofeng Zhang
file:C:/projects/f5/jsass/jcompass.jar!/gems/compass-core-1.0.1/stylesheets
and with this it should actually work - i.e. it look like a bug with the
windows absolute path and resources from within a jar !
so my "trick" needs a modification then
java -jar jcompass.jar -I classpath:/gems/compass-core-1.0.1/stylesheets
-S compass create MY_JPROJECT
but I admit it would be crude workaround (in case it really works).
Guofeng Zhang
2014-08-27 12:12:06 UTC
Permalink
The issue is not resolved. I made a mistake that I use another project (the
foundation project) that does not reference any sass file in the jar.

I copied the project from Windows 8 to a linux box (Ubuntu 12.04), the
project compile with compass successfully. so this a bug related to the
windows absolute path (as you said)

Will be there any patch or workarround for the bug?

I really saw the following line on the console:
file:C:/projects/f5/jsass/jcompass.jar!/gems/compass-
core-1.0.1/stylesheets
Post by Guofeng Zhang
This issue is solved by rolling back to Compass 0.12.7 and SASS 3.2.9. see
http://foundation.zurb.com/forum/posts/18630-scss-compiles-but-resulting-css-file-incomplete.
The last version of compass might have issues.
I really want to use Foundation with Compass, so I use ruby (not jruby) to
taste its sample and find that the compiled css file is very small and the
page is not styled. then I found the above link.
After rolled back,
java -jar jcompass.jar -S compass create MY_JPROJECT
or
java -jar jcompass.jar -S compass compile
worked well.
Thanks for your time very much.
Post by Guofeng Zhang
file:C:/projects/f5/jsass/jcompass.jar!/gems/compass-core-1.0.1/stylesheets
and with this it should actually work - i.e. it look like a bug with the
windows absolute path and resources from within a jar !
so my "trick" needs a modification then
java -jar jcompass.jar -I classpath:/gems/compass-core-1.0.1/stylesheets
-S compass create MY_JPROJECT
but I admit it would be crude workaround (in case it really works).
Loading...