Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Future.map doesn't work with dicts #64
The following code raises the error "string indices must be integers, not str":
I can make it work, however, by putting the dictionary in a list:
EDIT: In case the futures value is an iterable, the "map" function applies to each item consecutively. I find this unnecessary. This is has not been done for other "Future" implementations in other languages. See Scala.concurrent.Future:
Creates a new future by applying a function to the successful result of this future.