Git Product home page Git Product logo

zhugeio_spider's Introduction

主要运用技术

  session
  requests
  生成器
  token (模块已添加,目前诸葛io响应没有token)
  asyncio
  aiohttp

主要需求

  通过ajax 接口获取所有用户id,通过用户id获取用户数据
  用户基础数据,解析存储
  单个用户具体数据,解析存储

主要实现目标

  1.模拟登录,保持session
  2.异步协程获取所以用户数据,保存json文件
  3.过滤用户数据保存csv文件

代码说明

src/main/python/user_info
    client.py   模拟用户登录诸葛io
    config.py   配置请求诸葛io的url, 存储csv 格式定义, 存储json定义
    crawl.py    诸葛io 用户数据爬取,解析,存储json
    filterinfo.py   过滤json 数据存储 csv文件
    ftp.py      csv文件上传ftp服务器
    exception.py    自定义异常

生产环境使用

docker-compose up -d

遇到问题

  1.返回非json数据  text/html
   策略:
       1.1 请求加头
       1.2 延时,重新请求

zhugeio_spider's People

Contributors

runtangr avatar hcy7910 avatar

Stargazers

Zhigang.li avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.