Skip to main content

splash简单客户端

Project description

splashclient

简单的splash客户端

安装

pip install splashclient

快速入门

  • 初始化客户端,配置代理可以传递{"protocol": "http", "ip": "IP地址", "port": 端口}到参数default_proxy
splash_url = "你的splash服务端地址,例如:http://IP:8050"
client = SplashClient(splash_url, default_proxy=None, default_wait=0.1, default_time=30, default_header={
    "User-Agent": "abc"
})
  • 获取一个渲染后的网页html
html = client.render("http://blog.yubangweb.com")
print(html)
  • 获取页面截图
client.png("http://blog.yubangweb.com")
with open("1.png", "wb") as fp:
    fp.write(data)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

splashclient-0.0.1.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

splashclient-0.0.1-py3.6.egg (6.2 kB view details)

Uploaded Egg

File details

Details for the file splashclient-0.0.1.tar.gz.

File metadata

  • Download URL: splashclient-0.0.1.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.1

File hashes

Hashes for splashclient-0.0.1.tar.gz
Algorithm Hash digest
SHA256 3f52e3ffacd62456f8a98ef7656ec47e09dd0ab9e87918c1e814f4a0d9d2a30d
MD5 feb3d4abe38a6a0984df1ee3e6ca6333
BLAKE2b-256 474eb7f53c51f43f1d57843c19e78b81e4d5de6c8dd49622742a3ad91102b17c

See more details on using hashes here.

File details

Details for the file splashclient-0.0.1-py3.6.egg.

File metadata

  • Download URL: splashclient-0.0.1-py3.6.egg
  • Upload date:
  • Size: 6.2 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.1

File hashes

Hashes for splashclient-0.0.1-py3.6.egg
Algorithm Hash digest
SHA256 f74f17ab02215214742ef3080aab5b9632194f3e24b76af342d15a3732d262e2
MD5 623a42e032437eae671fb92d51bd7658
BLAKE2b-256 e770baca7db43cff5187f1c0a1d75de156bb46369a0ca1f72174f0a88a3e6231

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page