Message from Python discussions
November 2018
— S
Hello!
I'm a bit stuck and asking for a possible hint.
Subject: aiohttp
Question: How to reuse connection to host via proxy after getting the result (plain html)?
More info: I'm trying to make a reverse proxy with aiohttp.
I have 50 proxies and 1 destination host.
It seems, that creating 1 ClientSession and storing it in server app variable is the preferred way to go according to lib author.
How do I use this ClientSession instance to connect via different proxies and keeping the connections open to be reused?
Do you have any clue on where to dig further?
— Hi do somebody know how to save file from one location to another have tried the following but failed
—
to_save = QFileDialog.getSaveFileName(self, 'Save File', "", "All Files (*) (*.png) (*.jpg)")
src_dir = 'C:/Users/temp.jpg'
handle = open(src_dir, "rb")
h = open(to_save, "wb")
h.write(handle.read())
handle.close()
h.close()
— Amigos, algum brasileiro por ai on?
— !otherlanguages
— Thanks, dude!
— Shutil.copyfile2
— Hi, anyone familiar with DCP? trying to solve this problem: Given the mapping a = 1, b = 2, ... z = 26, and an encoded message, count the number of ways it can be decoded.
For example, the message '111' would give 3, since it could be decoded as 'aaa', 'ka', and 'ak'. - However i'm solving the extended version, i need to have a list of all possible string values derived from input rather than just count of possibilities. Would appreciate if anyone gives a clue.
— I have error
ParserError: Error tokenizing data. C error: Expected 1 fields in line 12, saw 2
Why?!
— I am having trouble converting a tuple into 2D array. Searched everywhere tried everything but can't get it done. This comma between coordinates is fking my brains. Any ideas?
— Because you're doing it wrong in line 12