Skip to main content

A collection of util functions for extracting domains from urls.

Project description

domain_utils

https://img.shields.io/pypi/v/domain_utils.svg https://img.shields.io/travis/mozilla/domain_utils.svg Documentation Status

A collection of util functions for extracting domains from urls.

Repo: https://github.com/mozilla/domain_utils

Install:

pip install domain_utils

Use:

import domain_utils as du
# Return just the url `my.domain.cloudfront.net/a/path/to/a/file.html`
du.get_stripped_url('https://my.domain.cloudfront.net/a/path/to/a/file.html?a=1')
# Return just the eTLD+1 `domain.cloudfront.net`
du.get_stripped_url('https://my.domain.cloudfront.net/a/path/to/a/file.html?a=1')

This package was originally extracted from openwpm-utils.

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.4.0 (2020-03-25)

  • Remove py27 support

0.3.0 (2020-03-25)

  • Restore py27 support.
  • Last version with py27 support.
  • Remove tox

0.2.0 (2020-03-24)

Project details


Download files

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

Files for domain-utils, version 0.4.0
Filename, size File type Python version Upload date Hashes
Filename, size domain_utils-0.4.0-py2.py3-none-any.whl (9.3 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size domain_utils-0.4.0.tar.gz (21.0 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page