Hi Khaleel and whoever this may help in the future,

Actually you were right Khaleel, on those lines i checked this thread which 
was useful to me.
https://stackoverflow.com/questions/122327/how-do-i-find-the-location-of-my-python-site-packages-directory

Following which i was stareing at the exception and realised that the clue 
which was in front of me since hours to resolve this issue.Like in Java, 
python gives you the root cause of an exception, but as i was used to Java 
and .Net i didnt realise the annotation used by python.

The exception i was bothered about the exception:
AppData\Roaming\Python\Python38\site-packages\django\db\utils.py", line 
121, in load_backend
    raise ImproperlyConfigured(
django.core.exceptions.ImproperlyConfigured: 'djongo' isn't an available 
database backend.
Try using 'django.db.backends.XXX', where XXX is one of:
    'mysql', 'oracle', 'postgresql', 'sqlite3'

Where as python had already listed the root cause which was :

\Python\Python38\site-packages\djongo\database.py", line 2, in <module>
    from pymongo import MongoClient
ModuleNotFoundError: No module named 'pymongo'

The *above exception was the direct cause *of the following exception:

Indeed that's where Khaleel you were right, PyMongo i installed through 
pycharm, which desginated a sitepackage folder that wasnt my user 
site-package...

Hope this helps someone falling into the same trap.

Cheers,
Es.

Le jeudi 19 mars 2020 21:35:52 UTC+1, Eswar Subramanyam a écrit :
>
> Hi 
>
> I opted for Djongo to take advantage of Django ORM with MongoDB..
>
> but while starting the server, i get the following error
>
> AppData\Roaming\Python\Python38\site-packages\django\db\utils.py", line 
> 121, in load_backend
>     raise ImproperlyConfigured(
> django.core.exceptions.ImproperlyConfigured: 'djongo' isn't an available 
> database backend.
> Try using 'django.db.backends.XXX', where XXX is one of:
>     'mysql', 'oracle', 'postgresql', 'sqlite3'
>
>
> I have lost a lot of time trying to figure out, and came to a conclusion 
> that i cant use ORM on Mongo DB.
>
> Have someone got a clue on what going wrong ?
>
> I dump also all the installed packages
>
> Thanks for your help/
>
> Package               Version
> --------------------- ----------
> asgiref               3.2.5
> bson                  0.5.8
> certifi               2019.11.28
> chardet               3.0.4
> dataclasses           0.6
> Django                2.2.11
> django-menu-generator 1.0.4
> djongo                1.3.1
> idna                  2.9
> mongoengine           0.19.1
> pip                   20.0.2
> pymango               0.1.1
> pymongo               3.10.1
> python-dateutil       2.8.1
> pytz                  2019.3
> requests              2.23.0
> setuptools            41.2.0
> six                   1.14.0
> sqlparse              0.2.4
> urllib3               1.25.8
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/2419aa99-7535-4bd5-b250-ca38d61b67bd%40googlegroups.com.

Reply via email to