TonyGen / mongodb-erlang

Fork of MongoDB driver for Erlang. mongodb now holds the master repository for this driver.
65 stars 16 forks source link

Unable to handle binary type 2 #11

Closed paulbjensen closed 5 years ago

paulbjensen commented 13 years ago

StackTrace:

exception error: no case clause matching 2
    in function  bson_binary:get_binary/1

Root of StackTrace:

bson/src/bson_binary.erl:132
pusewicz commented 13 years ago

Looks like this is the old binary type (which should be supported):

subtype ::= "\x00"  Binary / Generic
          | "\x01"  Function
          | "\x02"  Binary (Old)
          | "\x03"  UUID
          | "\x05"  MD5
          | "\x80"  User defined

http://bsonspec.org/#/specification

TonyGen commented 13 years ago

You must have created that data using an old driver. It's easy to add the case to read (but not write) that type. I will do it in a week or so. Submit a pull-request if you want it sooner. Cheers, Tony

pusewicz commented 13 years ago

Cool, that would be great, as I only need to read the data. I'll see if I can submit a patch.

Sent from my iPhone

On 14 Sep 2011, at 19:10, Tony Hannanreply@reply.github.com wrote:

You must have created that data using an old driver. It's easy to add the case to read (but not write) that type. I will do it in a week or so. Submit a pull-request if you want it sooner. Cheers, Tony

Reply to this email directly or view it on GitHub: https://github.com/TonyGen/mongodb-erlang/issues/11#issuecomment-2096181

paulbjensen commented 5 years ago

Closing as this is an old issue.