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
I think we may have a minor issue with the new conda package. I don't think it include pymongo and it probably should. The reason is that our Database class and others references bson and pymongo frequently. I got import errors trying to use it with a script using Database anyway. I had an old version of pymongo installed that I thought was causing a problem, but I did
pip uninstall pymongo
and then used conda to install pymongo in the same environment I had installed the mpsass package. It ran fine, BUT still get this error when try to use an instance of Database running it locally:
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
Cell In[2], line 1
----> 1 from bson.codec_options import CodecOptions, TypeRegistry, DatetimeConversion
ImportError: cannot import name 'DatetimeConversion' from 'bson.codec_options' (/home/pavlis/anaconda3/envs/mspass_py310/lib/python3.10/site-packages/bson/codec_options.py)
We need to fix this asap if we are going to use the package for upcoming workshops.
The text was updated successfully, but these errors were encountered:
I thought about making this a separate issues page, but the problem is closely related to the topic here. The conda package also lacks a package obspy uses to make some graphics called Cartopy. That package is used by the "plot" methods of Catalog and Inventory and maybe other things in obspy. Easy to see how it would be missed as is a secondary package for obspy for specialized map plots.
Since this is a dependency of ObsPy, it is probably their decision to not include the package as a normal dependency. I wonder we need to add it if we are not directly depending on it. I am actually fine either way, but @Aristoeu you may want to make the decision as you are working on this item.
I added Cartopy package in #515
I tried installing mspasspy in a new environment, it seems have included Pymongo, codec, and DatetimeConversion as I can import them successfully
I think we may have a minor issue with the new conda package. I don't think it include pymongo and it probably should. The reason is that our
Database
class and others references bson and pymongo frequently. I got import errors trying to use it with a script using Database anyway. I had an old version of pymongo installed that I thought was causing a problem, but I didand then used conda to install pymongo in the same environment I had installed the mpsass package. It ran fine, BUT still get this error when try to use an instance of
Database
running it locally:We need to fix this asap if we are going to use the package for upcoming workshops.
The text was updated successfully, but these errors were encountered: