Welcome to HTML-Jumping
- Author:
Daniel Perez Rada <@dperezrada>
What?
Allows to get an HTML, coming from several previous URLs. Sometimes this is needed to get webpages that requires cookies or a HTTP referrer to get a certain page.
Pre-requisites
You will need:
httplib2
http://socksipy.sourceforge.net/ (if you want to use a proxy)
To run the test you will also need:
lxml
Example
No proxy
from html_jumping import HtmlJumping
handler = HtmlJumping()
urls = [
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET'
},
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET',
'body': {
'term': 'html_jumping',
':action': 'search',
'submit': 'search'
}
}
]
received_header, received_content = handler.get(urls)
With proxy
Allow you to use a HTTP proxy, you will need to install the socksipy library.
from html_jumping import HtmlJumping
handler = HtmlJumping()
urls = [
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET'
},
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET',
'body': {
'term': 'html_jumping',
':action': 'search',
'submit': 'search'
}
}
]
received_header, received_content = handler.get(
urls,
proxy_info = {'host': '127.0.0.1', 'port': '8081'}
)
With permanent headers
This will sent in each call the headers ‘Accept-Language’.
from html_jumping import HtmlJumping
handler = HtmlJumping()
urls = [
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET'
},
{
'url': 'http://pypi.python.org/pypi',
'method': 'GET',
'body': {
'term': 'html_jumping',
':action': 'search',
'submit': 'search'
}
}
]
received_header, received_content = handler.get(
urls,
permanent_headers = {'Accept-Language': 'es, en-cl;q=0.5'}
)
Tests
Run
>> nosetests
Metadata
Release files for html_jumping 0.2.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| html_jumping-0.2.4.tar.gz | 3.7 kB | Without provenance | Details for html_jumping-0.2.4.tar.gz |
Release files / html_jumping-0.2.4.tar.gz
| Download URL | html_jumping-0.2.4.tar.gz |
|---|---|
| Size | 3.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8491722577a206530b09b80ea741e64fe3d96df8ac2e9c3683eb00f43a2ba5cf
|
|
BLAKE2b-256 checksum How to use checksums |
143696a45ddfca6766c29d18860072d0eb1f6b96c12eea6467e07008bda90857
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for html_jumping 0.2.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.