I did a stupid thing: MultipartStream expects the boundary to be specified without -- on the front. Now everything behaves correctly.
MultipartStream
--