1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-04-14 00:07:14 +03:00

Use older requests json syntax.

Newer syntax not supported on all recent Linux distros.
Reverts 786f34d.
This commit is contained in:
Jonathan Harris 2016-02-01 02:43:24 +00:00
parent c151396e4e
commit 0b2ed9614d

View File

@ -36,7 +36,7 @@ def send(cmdr, msg):
}
msg['message']['timestamp'] = time.strftime('%Y-%m-%dT%H:%M:%SZ', time.gmtime(config.getint('querytime') or int(time.time())))
r = requests.post(upload, json=msg, timeout=timeout)
r = requests.post(upload, data=json.dumps(msg), timeout=timeout)
if __debug__ and r.status_code != requests.codes.ok:
print 'Status\t%s' % r.status_code
print 'URL\t%s' % r.url