question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

code:

import uvloop
loop = uvloop.new_event_loop()
# loop = asyncio.get_event_loop()
chrome_executable_path = '/usr/lib64/chromium-browser/chromium-browser'
args = [
        "--disable-gpu",
        "--disable-web-security",
        "--disable-xss-auditor",    
        "--no-sandbox",
        "--disable-setuid-sandbox",
        "--allow-running-insecure-content",
        "--disable-webgl",
        "--disable-popup-blocking",
        '--disable-dev-shm-usage',
    ]
async def run(browser,url):
    page = await browser.newPage(ignoreHTTPSErrors=True)
    resp = await page.goto(url)
    print(resp.status)

async def main2():
    async with async_playwright() as p:
        browser_type = p.chromium
        browser = await browser_type.launch(executablePath=chrome_executable_path,args=args)
        task = [run(browser, f'http://www.baidu.com/s?wd={x}') for x in range(10)]
        await asyncio.gather(*task)
        await browser.close()
if __name__ == '__main__':
    loop.run_until_complete(main2())
    

out error:

python3: src/unix/core.c:932: uv__io_stop: Assertion `loop->watchers[w->fd] == w’ failed.

uvloop 0.14.0

playwright 0.171.1

python 3.8.3

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:11 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
blackAzraelcommented, Jan 14, 2021

thanks !

0reactions
pavelfeldmancommented, Jan 14, 2021

Closing as per MagicStack/uvloop#317 reference.

Read more comments on GitHub >

github_iconTop Results From Across the Web

pip install uvloop causes permission denied error
Then use pip install uvloop-XXX.whl. But I found that there is no version corresponding to python3.9. Share. Share a link to this answer....
Read more >
Bug #1745483 “[MIR] uvloop” : Bugs : uvloop package : Ubuntu
1. Availability: any 2. Rationale: uvloop is a new dependency that MAAS will use (in the next upload). This provides asyncio event loop...
Read more >
1718390 – python3-uvloop fails to import with Python 3.8
When built for Python 3.8.0b1, uvloop cannot be imported: >>> import uvloop Traceback (most recent call last): File "<stdin>", line 1, in <module>...
Read more >
uvloop Error in Bonus Mode - Google Groups
I've installed uvloop on my Ubuntu platform and have noticed that I am getting an issue during bonus mode when players "flipper cancel"...
Read more >
uvloop - PyPI
To make asyncio use uvloop, you can install the uvloop event loop policy: import asyncio import uvloop asyncio.set_event_loop_policy(uvloop.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found