os / slacker

Full-featured Python interface for the Slack API
Apache License 2.0
1.6k stars 245 forks source link

user requests.Session instead of requests.get|post #100

Closed hellysmile closed 7 years ago

hellysmile commented 7 years ago

It is bad practice to open\close TCP connection for each api request.

Client must create on __init__ requests.Session and explicitly close it.

simonsolnes commented 7 years ago

How could one fix that @hellysmile?

simonsolnes commented 7 years ago

https://github.com/os/slacker/commit/4405f6c7642ee340c898dc3475462ba04fda3d8f