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

昨天晚上写了个 Python 程序,下载了一个福利网站 5000 来张妹子图片

  •  3
     
  •   liuxu · Aug 24, 2015 · 20093 views
    This topic created in 4093 days ago, the information mentioned may be changed or developed.
    github:
    https://github.com/liuxu0315/download_nvshen_so

    执行:$ python nvshen_so.py

    用了多线程, 8 条线程,在 /tmp 下生成 nvshen_so/01 等文件夹并下载到相应的目录。
    里面有 2 行代码被注释掉了,它们是配套的,用来下载 2014/12/下的图片,有几百张。

    现在有个问题,我的程序无法一次全部下载完,总是漏一点,要么是执行一段时间后就卡死不动了不知道是什么原因。。
    当然下载图片前有判断是否有该文件,可以重复执行下载程序,不过这个治标没治本。。
    1  2  
    ❮ ❯
    aalska
    aalska
    Aug 25, 2015
    101
    @liuxu 没 难道是下载的问题? wget 下的


    下载 @Dongdong36 分享的两个也都是这样的报错
    liuxu
    liuxu
    OP
    Aug 25, 2015 via Android
    102
    @aalska 你下载的啥,我给的连接用 git clone 下载下来
    aalska
    aalska
    Aug 25, 2015
    104
    @Dongdong36 我是下代码的 非网页

    不过搞明白了 原因是系统问题
    aalska
    aalska
    Aug 26, 2015
    105
    @Dongdong36 我发现爬豆瓣妹子那个是没用的 豆瓣现在用的 dbmeinv 域名.....页面样式也不一样..
    bingoAI
    bingoAI
    Jul 4, 2016
    106
    再挖一下。
    5ipapa
    5ipapa
    Dec 22, 2022
    107
    cloudscraper 爬虫神器
    5ipapa
    5ipapa
    Feb 16, 2023
    108
    5ipapa 点 com 建议收藏
    1  2  
    ❮ ❯
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1863 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 07:07 · PVG 15:07 · LAX 23:07 · JFK 02:07
    ♥ Do have faith in what you're doing.