Fixing a deprecation warning
[doneit] / src / rtm_api.py
index 148ae7d..b617632 100644 (file)
@@ -3,13 +3,15 @@
 Python library for Remember The Milk API
 
 @note For help, see http://www.rememberthemilk.com/services/api/methods/
+
+@bug Under random situations, the response comes back incomplete.  Maybe a race condition, but how?
 """
 
 import weakref
 import warnings
 import urllib
 import urllib2
-from md5 import md5
+import hashlib
 
 _use_simplejson = False
 try:
@@ -81,7 +83,7 @@ class RTMapi(object):
        def _sign(self, params):
                "Sign the parameters with MD5 hash"
                pairs = ''.join(['%s%s' % (k, v) for (k, v) in sortedItems(params)])
-               return md5(self._secret+pairs).hexdigest()
+               return hashlib.md5(self._secret+pairs).hexdigest()
 
        @staticmethod
        def open_url(url, queryArgs=None):