Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: Async requests
Post: Async requests

Hello, Is there a way to have async requests in python using an http proxy, which has been set by the PAAS provider (pythonanywhere) on the requests module but not aiohttp which uses the websocket AP...
lukee General Coding Help 0 1,510 Oct-06-2020, 04:40 AM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

Just to restate the question for those not willing to read the whole thread, I'm simply wondering whether there's any way to have async requests in python using an http proxy, which has been set on th...
lukee General Coding Help 10 3,785 Oct-01-2020, 06:15 AM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

I'm stuck on this question, it's way past my knowledge, so if someone could help me I'd be grateful.
lukee General Coding Help 10 3,785 Sep-29-2020, 11:00 PM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

So any idea plz ?
lukee General Coding Help 10 3,785 Sep-27-2020, 11:10 PM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

It is true though, I've tried changing just one line from requests.get to session.get and in the later case it fails with a connect issue. See here, here or here. So is there a way to configure the p...
lukee General Coding Help 10 3,785 Sep-23-2020, 01:37 AM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

OKay so it appears pythonanywhere only sets up the http request, through a proxy (that whitelists some hosts though the one I'm interested in is whitelisted), and the websocket API that is used by aio...
lukee General Coding Help 10 3,785 Sep-22-2020, 02:00 AM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

Thanks for the idea, but didn't work. Anyway it wouldn't have explained why it works locally and not on pythonanywhere, or why it works with the sync'ed version and not async'ed.
lukee General Coding Help 10 3,785 Sep-21-2020, 07:22 PM
    Thread: Python error on pythonanywhere
Post: RE: Python error on pythonanywhere

It is a free account indeed, but it is part of the white-listed site, and works in sync mode. But I just coded an async version, and now it fails.
lukee General Coding Help 10 3,785 Sep-21-2020, 02:25 PM
    Thread: Python error on pythonanywhere
Post: Python error on pythonanywhere

Hello, so I have this error on deployment, I don't know if it's due to the constraints of my deployment server (pythonanywhere) or if it's related to something else. My code works locally, but when I...
lukee General Coding Help 10 3,785 Sep-21-2020, 02:13 PM
    Thread: Async / Await usage with asyncio to retrieve urls in parallel
Post: RE: Async / Await usage with asyncio to retrieve u...

Okay thanks, it seems I'm getting somewhere ! Two more questions: 1. The session is not reused in between the requests with that code, right ? Would it make the code much more complicated to make th...
lukee General Coding Help 7 3,099 Sep-20-2020, 08:58 PM
    Thread: Async / Await usage with asyncio to retrieve urls in parallel
Post: RE: Async / Await usage with asyncio to retrieve u...

I sure would love to post my experiments, but I'm really struggling to put it all together. I don't even know where to start. What I want seems fairly simple (just by looking at the sync version), and...
lukee General Coding Help 7 3,099 Sep-20-2020, 07:08 PM
    Thread: Async / Await usage with asyncio to retrieve urls in parallel
Post: RE: Async / Await usage with asyncio to retrieve u...

Thanks for your reply and sorry for the late response. I have some questions: - is it possible to make it such that all the asynchronous stuff occurs in the getResults() function, such that I don't ne...
lukee General Coding Help 7 3,099 Sep-20-2020, 04:41 PM
    Thread: Async / Await usage with asyncio to retrieve urls in parallel
Post: Async / Await usage with asyncio to retrieve urls ...

I'm looking for transform the following code into parallel execution : urls = ['http://example1.org', 'http://example2.org', '...'] def getResults(urls): results = {} for url in urls: result...
lukee General Coding Help 7 3,099 Sep-18-2020, 10:06 AM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020