V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
wc110302
V2EX  ›  Python

关于 pyqt5 中 runjavascript()方法的一个问题

  •  
  •   wc110302 · Aug 29, 2018 · 2922 views
    This topic created in 2803 days ago, the information mentioned may be changed or developed.
    当我使用 pyqt5 中内置的浏览器,并注入 js 来模拟操控时(view.loadFinished.connect(myjs), myjs 中是我的 runjavascript 方法),我发现这个方法会不停地注入 JS,当我使用 js 按钮进入下一个页面时,还没等继续按另一个按钮,整个 js 又加载了一次,导致我不能正常进行,现在有什么好的方法来解决吗,myjs 里面使用 time.sleep 会导致程序直接停住,想了各种办法都不行,或者有办法让 selenium 来执行 pyqt5 内置的浏览器么?我现在使用 pyqt5 主要是为了绕过一个反爬虫服务
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2432 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 07:50 · PVG 15:50 · LAX 00:50 · JFK 03:50
    ♥ Do have faith in what you're doing.