There are several considerations involved, but generally yes, you can change the versions of dependencies if they are binary compatible. The Scala team aims for 2.10.x releases to be binary compatible. You can compile against Scala 2.10.1 and use 2.10.3 at runtime.
You can generally do the reverse for the Scala library as long as you use methods and types that are present in both. Most libraries aren't concerned with this direction, though. Other caveats on binary compatibility:
- Different libraries have different policies on what version bumps mean.
- Libraries may or may not have automation to check binary compatibility.
- Automation like MiMa (used by Scala) does not catch all kinds of incompatibilities. For example, MiMa only catches "syntactic" incompatibilities (ones that throw
LinkageError
s at runtime). - Binary compatibility does not imply source compatibility.
It is not generally recommended to use dynamic revisions like "1.0.+", however. They make reproducing builds harder as well as affecting resolution speed.