images icon indicating copy to clipboard operation
images copied to clipboard

org.openqa.selenium.WebDriverException: json: cannot unmarshal string into Go struct field Caps.sessionTimeout of type uint32

Open YogeshMahajan1903 opened this issue 6 years ago • 11 comments

Observed with Centos-7, with Selenium - 3.11 & Selenoid -1.8.2

FirefoxOptions firefoxOption = new FirefoxOptions(); firefoxOption.setAcceptInsecureCerts(true); firefoxOption.setHeadless(false); firefoxOption.addArguments("-foreground"); firefoxOption.setCapability("version", version); firefoxOption.setCapability("enableVNC", true); firefoxOption.setCapability("enableVideo", true); firefoxOption.setCapability("videoName",videoName+".mp4"); firefoxOption.setCapability("logName",videoName+".log"); firefoxOption.setCapability("name",videoName); firefoxOption.setCapability("platform", Platform.LINUX); firefoxOption.setCapability("resolve_ip", false); firefoxOption.setCapability("sessionTimeout", "60s");

When launched with above configuration, Exception thrown - org.openqa.selenium.WebDriverException: json: cannot unmarshal string into Go struct field Caps.sessionTimeout of type uint32.

YogeshMahajan1903 avatar Nov 21 '18 08:11 YogeshMahajan1903

@YogeshMahajan1903 see Breaking Changes section here: https://github.com/aerokube/selenoid/releases/tag/1.8.0

vania-pooh avatar Nov 21 '18 09:11 vania-pooh

Yup, I had checked above issue before logging issue. Tried all formats - ""60s" or "1m" or "2m10s" or "1h"" None of it works

YogeshMahajan1903 avatar Nov 21 '18 09:11 YogeshMahajan1903

@YogeshMahajan1903 in that case you have old Selenoid version which required just a number of seconds:

sessionTimeout = 60

vania-pooh avatar Nov 21 '18 12:11 vania-pooh

sessionTimeout = 60 this works with Selenoid -1.7.2. With Selenoid neither 60 nor 60s works

YogeshMahajan1903 avatar Nov 21 '18 12:11 YogeshMahajan1903

sessionTimeout = 60 this works with Selenoid -1.7.2. With Selenoid 1.8.2 neither 60 nor 60s works

YogeshMahajan1903 avatar Nov 21 '18 12:11 YogeshMahajan1903

@YogeshMahajan1903 will check soon.

vania-pooh avatar Nov 21 '18 13:11 vania-pooh

@YogeshMahajan1903 ok, that's an issue in Firefox images. Should work with Firefox 63.0 image but will not work before. I will rebuild images during next weeks.

vania-pooh avatar Nov 21 '18 16:11 vania-pooh

It works with Firefox - 63. So I guess images need to be rebuild for older version

YogeshMahajan1903 avatar Nov 22 '18 09:11 YogeshMahajan1903

@YogeshMahajan1903 yes. That's not a Selenoid code issue. It will also work with any other non-Firefox image.

vania-pooh avatar Nov 22 '18 10:11 vania-pooh

Still here :)

Asgoret avatar Apr 22 '20 15:04 Asgoret

@Asgoret we know.

vania-pooh avatar Apr 23 '20 15:04 vania-pooh