Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

连续运行3小时左右,程序就会卡死 #47

Open
Cuile opened this issue Feb 14, 2020 · 2 comments
Open

连续运行3小时左右,程序就会卡死 #47

Cuile opened this issue Feb 14, 2020 · 2 comments

Comments

@Cuile
Copy link

Cuile commented Feb 14, 2020

已经发生好几次,连续运行3小时左右,程序就会卡死,ctrl+c中止了程序,就得到了下面的报错信息,好像是线程超时了?

Traceback (most recent call last):
  File "test.py", line 174, in <module>
    test()
  File "test.py", line 122, in test
    r.script.load_jQuery_script("jquery-3.4.1.slim.min.js")
  File "/root/code/robot/script.py", line 37, in load_jQuery_script
    res = self.run_script(script, 3000)
  File "/root/code/robot/script.py", line 22, in run_script
    expression=script, returnByValue=True, timeout=timeout
  File "/usr/local/lib/python3.7/site-packages/pychrome/tab.py", line 174, in call_method
    result = self._send({"method": _method, "params": kwargs}, timeout=timeout)
  File "/usr/local/lib/python3.7/site-packages/pychrome/tab.py", line 106, in _send
    return self.method_results[message['id']].get(timeout=q_timeout)
  File "/usr/local/lib/python3.7/queue.py", line 179, in get
    self.not_empty.wait(remaining)
  File "/usr/local/lib/python3.7/threading.py", line 300, in wait
    gotit = waiter.acquire(True, timeout)

我使用docker环境,python:3.7+alpeware/chrome-headless-stable:latest

@Cuile Cuile changed the title 连续运行3小时左右,程序就是卡死 连续运行3小时左右,程序就会卡死 Feb 14, 2020
@yuhuan0311
Copy link

你好,能请教一下你的脚本是怎么运行起来的吗?我用作者项目里面的demo文件,运行的时候就会报错:
(Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x11026f510>: Failed to establish a new connection: [Errno 61] Connection refused'))
是不是还应该写些什么别的代码才能运行起来呢?

@Cuile
Copy link
Author

Cuile commented Jul 22, 2020

你好,能请教一下你的脚本是怎么运行起来的吗?我用作者项目里面的demo文件,运行的时候就会报错:
(Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x11026f510>: Failed to establish a new connection: [Errno 61] Connection refused'))
是不是还应该写些什么别的代码才能运行起来呢?

你这个问题好难回答,不知道你现在什么环境

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants