Type mismatch (Session -> Validation[Session])


exec(session => {



Trying to setup the above based on examples I have read but getting a type mismatch. Not sure how to correct it. Anyone able to offer guidance?


[ERROR] CombinedReadWrite.scala:56: error: type mismatch;
[ERROR] found : io.gatling.core.session.Session
[ERROR] required: io.gatling.core.validation.Validation[io.gatling.core.session.Session]
[ERROR] session

[ERROR] one error found



You probably miss the standard import:

import io.gatling.core.Predef._

Perfect thanks. Problem with Eclipse was it had one import statement per import. There is an option to always wildcard import specific packages so added io.gatling.core.Predef and io.gatling.http.Predef to the list and it works like a charm.