You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MongoDB uses ObjectId in _id field, and it's useful to use these to refer to genes/hits in the database, since these are by definition unique and look-up is incredibly fast. But, when writing genes out to fasta files, ObjectIds are written as strings, and I failed to convert them back into ObjectId when putting them into blast_results database. There might be other places where this mistake was made as well, and there are a bunch of places where I'm converting the string representation to ObjectId and back again.
All uses should be the same, so I think any time these identifiers are in the database, they should be represented by ObjectIds, not strings. The only time conversion should happen is when they're written to files or pulled in from files.
The text was updated successfully, but these errors were encountered:
MongoDB uses
ObjectId
in_id
field, and it's useful to use these to refer to genes/hits in the database, since these are by definition unique and look-up is incredibly fast. But, when writing genes out to fasta files,ObjectId
s are written as strings, and I failed to convert them back intoObjectId
when putting them intoblast_results
database. There might be other places where this mistake was made as well, and there are a bunch of places where I'm converting the string representation toObjectId
and back again.All uses should be the same, so I think any time these identifiers are in the database, they should be represented by
ObjectId
s, not strings. The only time conversion should happen is when they're written to files or pulled in from files.The text was updated successfully, but these errors were encountered: