ImportError: cannot import name '_get_object_size' from 'bson'

C:\Users\Dell\Downloads\mflix-python>activate mflix

(mflix) C:\Users\Dell\Downloads\mflix-python>python run.py
Traceback (most recent call last):
  File "C:\Users\Dell\Downloads\mflix-python\run.py", line 1, in <module>
    from mflix.factory import create_app
  File "C:\Users\Dell\Downloads\mflix-python\mflix\factory.py", line 12, in <module>
    from mflix.api.movies import movies_api_v1
  File "C:\Users\Dell\Downloads\mflix-python\mflix\api\movies.py", line 2, in <module>
    from mflix.db import get_movie, get_movies, get_movies_by_country, \
  File "C:\Users\Dell\Downloads\mflix-python\mflix\db.py", line 15, in <module>
    from pymongo import MongoClient, DESCENDING, ASCENDING
  File "C:\Users\Dell\anaconda3\envs\mflix\lib\site-packages\pymongo\__init__.py", line 89, in <module>
    from pymongo.collection import ReturnDocument
  File "C:\Users\Dell\anaconda3\envs\mflix\lib\site-packages\pymongo\collection.py", line 35, in <module>
    from bson.raw_bson import RawBSONDocument
  File "C:\Users\Dell\anaconda3\envs\mflix\lib\site-packages\bson\raw_bson.py", line 56, in <module>
    from bson import _get_object_size, _raw_to_dict
ImportError: cannot import name '_get_object_size' from 'bson' (C:\Users\Dell\anaconda3\envs\mflix\lib\site-packages\bson\__init__.py)

How to resolve this

Hey @Hemanth_Reddy,

Have you installed all the required libraries from the requirements.txt file before running the python run.py command? Furthermore, which version of python are you using?

Regards,
Satyam