Selenium library:run_on_failure=Capture Screenshot ERROR: java.io.FileNotFoundException

152 views
Skip to first unread message

WilliamZhang

unread,
Nov 29, 2010, 3:02:21 AM11/29/10
to robotframework-users
Anybody knows why this function throw out the error?
----
ERROR: java.io.FileNotFoundException: /var/folders/yC/yC-BR3EaE+0V23rq
+scaok+++TI/-Tmp-/customProfileDir9b54401dac2c40f19022e892b0290b79/
screenshots/page-screenshot-9b54401dac2c40f19022e892b0290b79.png (No
such file or directory)

----Environment infomation----
Java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02-279-10M3065)
Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01-279, mixed mode)
Selenium RC server v2.0 a7 and selenium library 2.5 ;Robot Framework
2.5.4 (Python 2.6.1)

Franz Allan Valencia See

unread,
Nov 29, 2010, 3:42:10 AM11/29/10
to jolly...@gmail.com, robotframework-users
Does that file exist? /var/folders/yC/yC-BR3EaE+0V23rq+scaok+++TI/-Tmp-/customProfileDir9b54401dac2c40f19022e892b0290b79/screenshots/page-screenshot-9b54401dac2c40f19022e892b0290b79.png

Cheers,

--
Franz Allan Valencia See | Java Software Engineer
fran...@gmail.com
LinkedIn: http://www.linkedin.com/in/franzsee
Twitter: http://www.twitter.com/franz_see


--
You received this message because you are subscribed to the Google Groups "robotframework-users" group.
To post to this group, send email to robotframe...@googlegroups.com.
To unsubscribe from this group, send email to robotframework-u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/robotframework-users?hl=en.




William Zhang

unread,
Nov 29, 2010, 3:54:00 AM11/29/10
to Franz Allan Valencia See, robotframework-users
no
I re-run the test cases and ls the folder.

When the issue displayy:
ERROR: java.io.FileNotFoundException:
/var/folders/yC/yC-BR3EaE+0V23rq+scaok+++TI/-Tmp-/customProfileDirfbb5bd519983419d8e8c3922cf3edcaf/screenshots/page-screenshot-fbb5bd519983419d8e8c3922cf3edcaf.png


(No such file or directory)

-----
>>>ls /var/folders/yC/yC-BR3EaE+0V23rq+scaok+++TI/-Tmp-/
>>>
drwxr-xr-x 29 jollychang staff 986 11 29 16:46
customProfileDirfe0d8467f3a2442cac9aa3aa4af617ea
-rw-r--r-- 1 jollychang staff 6045 11 29 16:46
fe0d8467f3a2442cac9aa3aa4af617ea5730479201410303215.rclog

There is no the customProfileDirfbb5bd519983419d8e8c3922cf3edcaf folder

I checkout the rclog,last line is

>>>this may lead to a 'Permission denied' from the browser (unless it is running as *iehta or *chrome,


------


William
--------------------
This is the life!

Franz Allan Valencia See

unread,
Nov 29, 2010, 4:58:08 AM11/29/10
to William Zhang, robotframework-users
Just on top of my head, /var/folders/yC/yC-BR3EaE+0V23rq+scaok+++TI/-Tmp-/ (or /var/folders) is probably writable to your running process.

If it's ok with you, how about doing a `chmod a+w /var/folders -R` (note: you might want to backup it up first with something like a `cp /var/folders /var/folders.bak` just in case)


Cheers,
--
Franz Allan Valencia See | Java Software Engineer
fran...@gmail.com
LinkedIn: http://www.linkedin.com/in/franzsee
Twitter: http://www.twitter.com/franz_see


William Zhang

unread,
Nov 29, 2010, 5:47:34 AM11/29/10
to Franz Allan Valencia See, robotframework-users
all the folders has chmod to 777
this issue is not relate for my OS's file system permission


William
--------------------
This is the life!

Pekka Klärck

unread,
Dec 2, 2010, 4:23:21 PM12/2/10
to jolly...@gmail.com, robotframework-users
2010/11/29 WilliamZhang <jolly...@gmail.com>:

> Anybody knows why this function throw out the error?
> ----
> ERROR: java.io.FileNotFoundException: /var/folders/yC/yC-BR3EaE+0V23rq
> +scaok+++TI/-Tmp-/customProfileDir9b54401dac2c40f19022e892b0290b79/
> screenshots/page-screenshot-9b54401dac2c40f19022e892b0290b79.png (No
> such file or directory)

Have you tried does running Capture Screenshot fail the same way if
you use it normally?

Cheers,
.peke
--
Agile Tester/Developer/Consultant :: http://eliga.fi
Lead Developer of Robot Framework :: http://robotframework.org

William Zhang

unread,
Dec 2, 2010, 9:25:41 PM12/2/10
to Pekka Klärck, robotframework-users
The same when user the Capture Page Screenshot from seleniumlibrary


William
--------------------
This is the life!

William Zhang

unread,
Dec 13, 2010, 12:52:07 AM12/13/10
to Pekka Klärck, robotframework-users
But when I use the remove the "run_on_failure" from SeleniumLibrary
It works,it only got the issue by run_on_failure=Capture Page Screenshot

William
--------------------
This is the life!

Reply all
Reply to author
Forward
0 new messages