Closed aisayko closed 9 years ago
This can occur if the response from Mandrill is being truncated or altered. I'd guess the problem may be related to the urllib3 warning you're seeing:
InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
The link they provide has some suggestions.
Next steps solved the issue:
apt-get install libffi-dev libssl-dev
pip install requests[security] --upgrade
Thanks!
Glad you found a solution.
For anyone else reading this issue because you're seeing an InsecurePlatformWarning
when using Djrill, the solution is either:
requests[security]
package extras (and any additional OS support that requires) as in the comment aboveMore details here.
data = urllib.urlencode(parameters).encode('utf-8') content = urllib2.urlopen(url=token_url, data=data) try: string = content.read() json_obj = json.loads(string.decode('utf-8')) print json_obj except ValueError as a: print a else: print json_obj
any one have idea it gives value error like " No JSON object could be decoded"
@aisayko i tried this but it give me still error.....
@McaDipali are you having a problem with the Djrill package? The code you posted doesn't look like anything from Djrill.
If your question is not about Djrill, please ask it on StackOverflow.
If you are having problems with Djrill, it might be better to open a new issue. Be sure to say what versions of Djrill, Django, requests, and Python you are using; what specifically you are trying to do that's not working; and include any stack trace from the failure. (Also, please note that Djrill is no longer being supported.)
Hello,
I just installed Djrill and try to send test message:
The message is sent successfully to user but the code raise the next error:
Python == 2.7.6 Django == 1.8.2 djrill == 1.4.0
Many thanks for any help.