def fucking_send(solution): # manpages, hands off! # at least this piece works s = json.dumps(solution) hdr = {'content-type': 'application/json'} r = requests.post( goldcfg.url(), auth=('', goldcfg.token()), data=s, headers=hdr) assert r.text == 'created' print('sent')
def run(s): hdr = {'content-type': 'application/json'} r = req.post(goldcfg.url(), auth=('', goldcfg.token()), data=s, headers=hdr) return r.text == 'created'
def referenceResults(): r = req.get(goldcfg.url(), auth=('', goldcfg.token())) return json.loads(r.text)