vbauer / manet

Website screenshot service powered by Node.js, SlimerJS and PhantomJS
MIT License
575 stars 102 forks source link

Unable to open file 'src/config/default-styles.css' #26

Closed jfix closed 9 years ago

jfix commented 9 years ago

attempting to retrieve google.com screenshot of a just reinstalled and started manet:

$ /usr/local/lib/node_modules/manet/bin/manet --port 3000
debug: Initialize FS watchdog: directory: /tmp, timeout: 3600000
info: Manet server started on port 3000
debug: Sending image ("google.com") in response
info: Capture site screenshot: google.com
debug: Options for script: {"url":"http://google.com"}, base64: eyJ1cmwiOiJodHRwOi8vZ29vZ2xlLmNvbSJ9
exec: use child_process.execFile instead
debug: Process output: Script options: {"url":"http://google.com"}
Error: Unable to open file 'src/config/default-styles.css'

error: Process error: Fontconfig warning: ignoring UTF-8: not a valid region tag

Apart from the default-styles.css that can't be found anymore (but is in the same place), and the Fontconfig error that is probably due to a phantomjs issue(?), I can no longer generate snapshots. Not even uncompressed ones.

Any ideas? Thanks!

jfix commented 9 years ago

related to #22

vbauer commented 9 years ago

Yes, I've already faced with this issue. PhantomJS doesn't work correctly with relative paths and it looks like we haven't got possibility to retrieve information about file path correctly inside PhantomJS script.

More details could be found here: https://github.com/ariya/phantomjs/issues/10330

I've just removed this feature. Maybe in future it will be better to pass this parameters to PhantomJS/SlimerJS from Node part.

vbauer commented 9 years ago

Try to update Manet to the version 0.3.5. I hope you problems will be solved.