Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-4098

result of bson.Timestamp.add is Long not a Timestamp

    • Type: Icon: Bug Bug
    • Resolution: Won't Fix
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: BSON
    • 0
    • Not Needed

      What problem are you facing?

      > node
      > bson = require('bson')
      > bson.Timestamp.fromNumber(0).add(bson.Timestamp.ONE)
      new Long("1", true)
      

      Then after saving such a result in the database and fetching it bach, it comes as Long("1") (unsigned). This messes up deep equality assertions in tests

      What driver and relevant dependency versions are you using?

      mongodb@4.3.1
      bson@4.6.1

      Steps to reproduce?

      describes in first section above

            Assignee:
            bailey.pearson@mongodb.com Bailey Pearson
            Reporter:
            adrian.gierakowski@deversifi.com Adrian Gierakowski
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: