Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I stop using a deprecated module?

I am using django-registration v0.7 and django 1.2.4. Everything works fine but I am wondering why I'm getting this warning message each time I run the server:

 C:\Python26\lib\site-packages\registration\models.py:4: DeprecationWarning: the sha module is deprec
    ated; use the hashlib module instead
      import sha

Could be a problem in the future? Can I avoid it without changing django-registration original code?

EDIT This deprecation warning comes up in Python 2.6.2

like image 846
juankysmith Avatar asked Sep 02 '25 14:09

juankysmith


1 Answers

No, if it works, leave it. You can consider this something to think about when you upgrade to a new version of Python which actually removes this module.

Deprecated means that you are encouraged not to use it in new code, it doesn't mean you need to modify (and hence break) existing code which uses it.

like image 189
MarkR Avatar answered Sep 05 '25 15:09

MarkR