My project P depends on dependency A which depends on dependency B. My project\'s pom.xml file includes A as a dependency, and its jar is included in P\'s classpath. Howev
I'm writing my own solution/situation since none of the other answers solved my problem.
In my case, my project (ME) was dependant on another project (LIB) which was dependant on another project (open-csv).
However, I noticed an older version of open-csv is already a dependency in my project, and probably this force the second library (LIB) use this older version of open-csv library, which does not contain a newer class used by LIB.
I solved the issue by updating the version of open-csv in my main project dependency list.