popravich on travis_pypy
.travis.yml: chaching pip packa… Makefile: build/install only re… .travis.yml: cache redis-server… (compare)
RuntimeError: Session is closed
Hi, I was making a custom MultiPart form-data request and got a 502 (it's either nginx or Apache, so standard).
Commenting out this line was what made the request successful:
Is this covered by some standard?
helpers.content_disposition_headerwhether to encode the field value or not. In my case, it was an ASCII string. Also,
curldidn't encode it.
wraptileposted an image:
wraptilethe docs here are incorrect as dict is invalid type
ValueError: dictionary update sequence element #0 has length 9; 2 is required
wraptilewhat's the de facto way to serialize/deserialize session? For cookies it seems to be awfully complicated
async def test_cookies():
async with ClientSession() as session:
session.cookie_jar.update_cookies(SimpleCookie('login=jogn; Path=/; Domain=httpbin.org'))
session.cookie_jar.update_cookies(SimpleCookie('pass=snow; Path=/; Domain=httpbin.org'))
cookies = pickle.dumps(session.cookie_jar._cookies)
resp = await session.get('http://httpbin.org/cookies')
async with ClientSession() as session: session.cookie_jar._cookies = pickle.loads(cookies) print(await resp.text())
wraptilethis is kinda ugly, but I guess it should work fine? 😬
wraptileI see the bridge doesn't format the code snippet well either, ugh. Maybe now that Matrix bought gitter they can finally fix this