推荐学习书目
› 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
chjf2008
V2EX  ›  Python

lua 脚本调用 splash 内存不回收 怎么处理 第一次发帖。

  •  
  •   chjf2008 · Sep 18, 2020 · 1981 views
    This topic created in 2202 days ago, the information mentioned may be changed or developed.

    安装了在 docker 上安装了 splash,用 scrapy 调用了 4 个网页请求,执行了 lua,请求结束了,但是内存不回收,如何处理?

    2 replies  •  2020-09-18 17:16:01 +08:00
    knightdf
        1
    knightdf  
       Sep 18, 2020
    是不是用全局变量了,lua 非 local 变量全部是全局变量
    chjf2008
        2
    chjf2008  
    OP
       Sep 18, 2020
    @knightdf lua 只是设置了一个 select 的值 然后点击按钮
    document.getElementById("quantity").options[document.getElementById("quantity").selectedIndex].value=9999;document.querySelector("#add-to-cart-button").click()
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4619 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 35ms · UTC 03:54 · PVG 11:54 · LAX 20:54 · JFK 23:54
    ♥ Do have faith in what you're doing.