[FilePath, Camera] ENCODING_ERR when selecting file from google drive

When selecting file from phone’s library, I have access to gallery, videos, dropbox, google drive etc. Selecting file from google drive works when MediaType is set to PICTURES, it fails with ENCODING_ERR when MediaType is set to ALLMEDIA (which I need, because I want both photos and videos to be available). Can you help me with this?