Python has (1,) for a single element tuple. In Scala, (1,2) works for Tuple2(1,2) but we must use Tuple1(1) to get a sin
(1,)
(1,2)
Tuple2(1,2)
Tuple1(1)
You could, of course, add an implicit conversion to your API:
implicit def value2tuple[A](x: A) = Tuple1(x)
I do find it odd that Tuple1.toString includes the trailing comma:
Tuple1.toString
scala> Tuple1(1) res0: (Int,) = (1,)