Closed hkethi002 closed 6 years ago
Merging #981 into master will not change coverage. The diff coverage is
0%
.
@@ Coverage Diff @@
## master #981 +/- ##
=====================================
Coverage 90% 90%
=====================================
Files 49 49
Lines 6640 6640
=====================================
Hits 5976 5976
Misses 664 664
What am I missing here?
>>> import bson
>>> bson.errors.InvalidId
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'errors'
$ pip list | grep bson
bson (0.5.0)
So when I first imported bson, I was getting the same error, but after installing pymongo as well, then I had access to the InvalidId exception.
Harsha-Macbook-Pro:Clear harshakethineni$ python
Python 2.7.10 (default, Feb 7 2017, 00:08:15)
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import bson
>>> bson.errors.InvalidId
<class 'bson.errors.InvalidId'>
Harsha-Macbook-Pro:Clear harshakethineni$ pip list | grep bson
DEPRECATION: The default format will switch to columns in the future. You can use --format=(legacy|columns) (or define a format=(legacy|columns) in your pip.conf under the [list] section) to disable this warning.
bson (0.5.0)
Was getting this error in the log traceback
http://api.mongodb.com/python/current/api/bson/errors.html
Review Checklist