Skip to main content

Scrap Utils

This is small package that contains some code regularly repeated when scraping.

To install

pip install scrap-utils

Sample code

import scrap_utils as su

response = su.requests_get("https://python.org")
len(response.text)

It has the following functions:

load_json(filepath, encoding=None, errors=None, parse_float=None,
	parse_int=None, parse_constant=None)

dump_json(data, filepath, encoding=None, errors=None, indent=4, skipkeys=False,
	ensure_ascii=False, separators=None, sort_keys=False)

to_csv(dataset, filepath, mode="a", encoding=None, errors=None, newline='',
	header=True, dialect='excel', **fmtparams)

requests_get(url, trials=0, sleep_time=30, max_try=math.inf, **requests_kwargs)

requests_post(url, trials=0, sleep_time=30, max_try=math.inf, **requests_kwargs)

To-do list I'm considering:

  • remove print statements
  • add unittest
  • soup_get()
  • driver_get()
  • start_firefox()
  • read_csv()

Feel free to add your contribution here

Metadata

Release files for scrap-utils 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for scrap-utils 0.0.2
File Size Uploaded Provenance
scrap-utils-0.0.2.tar.gz 3.5 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for scrap-utils 0.0.2
File Interpreter ABI Platform
scrap_utils-0.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 7.5 kB

Release files / scrap-utils-0.0.2.tar.gz

Download URL scrap-utils-0.0.2.tar.gz
Size 3.5 kB
Tags Source
SHA-256 checksum
How to use checksums
c7de35ab09292d19966c35e57099124489fc09be9580ab52cccae8e16b8b4c41
BLAKE2b-256 checksum
How to use checksums
98a0f76b97f323bc4644a114d1f2866bb3d816935a3353e065afedea06b61902
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.1

Release files / scrap_utils-0.0.2-py3-none-any.whl

Download URL scrap_utils-0.0.2-py3-none-any.whl
Size 3.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
df812d0576a405229b60f10e21d9d9c54c0d732ce676dd9896388e68e79ad907
BLAKE2b-256 checksum
How to use checksums
606411f9ac926aa43ae783fd5de3e0fa4e79d76c97d9ec1c956b7e8a64a167c6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.1

Security for scrap-utils 0.0.2

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page