`easyuri` is a dumb URL parser with a smart interface.
>>> import easyuri
>>> uri = easyuri.parse("en.wikipedia.org/wiki/Jabberwocky")
>>> uri.is_secure, uri.in_hsts
(True, True)
>>> uri.scheme, uri.host, uri.port
('https', 'en.wikipedia.org', 443)
>>> uri.subdomain, uri.domain, uri.suffix, uri.path
('en', 'wikipedia', 'org', 'wiki/Jabberwocky')
>>> str(uri)
'https://en.wikipedia.org/wiki/Jabberwocky'
>>> uri = easyuri.parse("http://evil.com\\@good.com/") # doctest: +IGNORE_EXCEPTION_DETAIL
Traceback (most recent call last):
...
DifficultURLError
Raw data
{
"_id": null,
"home_page": "https://ragt.ag/code/projects/easyuri",
"name": "easyuri",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8,<3.11",
"maintainer_email": "",
"keywords": "web,www",
"author": "Angelo Gladding",
"author_email": "angelo@ragt.ag",
"download_url": "https://files.pythonhosted.org/packages/44/f4/7e83f566fdc2dd0c3225615a9c15f8c51cb2865b2153d2a088983bd7b5a8/easyuri-0.1.4.tar.gz",
"platform": null,
"description": "`easyuri` is a dumb URL parser with a smart interface.\n\n >>> import easyuri\n >>> uri = easyuri.parse(\"en.wikipedia.org/wiki/Jabberwocky\")\n >>> uri.is_secure, uri.in_hsts\n (True, True)\n >>> uri.scheme, uri.host, uri.port\n ('https', 'en.wikipedia.org', 443)\n >>> uri.subdomain, uri.domain, uri.suffix, uri.path\n ('en', 'wikipedia', 'org', 'wiki/Jabberwocky')\n >>> str(uri)\n 'https://en.wikipedia.org/wiki/Jabberwocky'\n\n >>> uri = easyuri.parse(\"http://evil.com\\\\@good.com/\") # doctest: +IGNORE_EXCEPTION_DETAIL\n Traceback (most recent call last):\n ...\n DifficultURLError\n",
"bugtrack_url": null,
"license": "BSD-2-Clause",
"summary": "a dumb URL parser with a smart interface",
"version": "0.1.4",
"project_urls": {
"Documentation": "https://ragt.ag/code/projects/easyuri/api",
"Homepage": "https://ragt.ag/code/projects/easyuri",
"Repository": "https://ragt.ag/code/projects/easyuri.git"
},
"split_keywords": [
"web",
"www"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "1b4e6abd32dbc18cfeb8559e8f364574adbd4980ef04c6e8ccca1c651b26aa6c",
"md5": "e572a609caefd15ba43a3af4d6506841",
"sha256": "4646ab4bf2b2c47c0eea2a2c7f819834d86f0ea65eaa29bc2ff3200fafea2db0"
},
"downloads": -1,
"filename": "easyuri-0.1.4-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e572a609caefd15ba43a3af4d6506841",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8,<3.11",
"size": 7012,
"upload_time": "2023-08-05T03:14:22",
"upload_time_iso_8601": "2023-08-05T03:14:22.617535Z",
"url": "https://files.pythonhosted.org/packages/1b/4e/6abd32dbc18cfeb8559e8f364574adbd4980ef04c6e8ccca1c651b26aa6c/easyuri-0.1.4-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "44f47e83f566fdc2dd0c3225615a9c15f8c51cb2865b2153d2a088983bd7b5a8",
"md5": "80c8f7c1eb1daaef2ad09e8a01ebf5fe",
"sha256": "e4775bf66c1bf0455ba5565e3c58ba484d43ec8c668207001688aa8e1784fbc0"
},
"downloads": -1,
"filename": "easyuri-0.1.4.tar.gz",
"has_sig": false,
"md5_digest": "80c8f7c1eb1daaef2ad09e8a01ebf5fe",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8,<3.11",
"size": 7044,
"upload_time": "2023-08-05T03:14:24",
"upload_time_iso_8601": "2023-08-05T03:14:24.015552Z",
"url": "https://files.pythonhosted.org/packages/44/f4/7e83f566fdc2dd0c3225615a9c15f8c51cb2865b2153d2a088983bd7b5a8/easyuri-0.1.4.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-08-05 03:14:24",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "easyuri"
}