When using Selenium remember that if you are connecting to a linux grid the url for the remote driver is case sensitive.
Mostly when you get this error it is because the url to the grid is wrong !
eg. http://192.168.99.100:4444/wd/hub
System.InvalidCastException
Unable to cast object of type 'System.String' to type
'System.Collections.Generic.Dictionary`2[System.String,System.Object]'.
at OpenQA.Selenium.Remote.RemoteWebDriver.StartSession(ICapabilities desiredCapabilities)
at OpenQA.Selenium.Remote.RemoteWebDriver..ctor(ICommandExecutor commandExecutor, ICapabilities desiredCapabilities)
at OpenQA.Selenium.Remote.RemoteWebDriver..ctor(Uri remoteAddress, ICapabilities desiredCapabilities)
at ken.Selenium.Errors.SeleniumTests.ShouldHaveNoJavascriptErrors(String url) in d:\Sources.Sandbox\Ken\ken.Selenium.Errors\...\SeleniumTests.cs:line 79