typename


Nametypename JSON
Version 1.0.4 PyPI version JSON
download
home_pagehttps://github.com/sixty-north/typename
SummaryObtain the name of the type of an object
upload_time2023-05-11 08:49:00
maintainer
docs_urlNone
authorSixty North
requires_python
licenseMIT License
keywords python types typename
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Typename

![CI](https://github.com/sixty-north/typename/actions/workflows/actions.yml/badge.svg)

The `typename` module defines a single function also called `typename` which returns the name of the
type of any object as a string.

Its purpose is purely aesthetic, to avoid unsightly constructs such as `type(obj).__name__` or the
ghastly `obj.__class__.__name__`.

# Installation

The `typename` package is available on the Python Package Index (PyPI):

[![PyPI version](https://badge.fury.io/py/typename.svg)](https://badge.fury.io/py/typename)

*Typename* should work with any version of Python 3. To install:

With `pip` from PyPI:

    pip install typename

# How to use

    >>> from typename import typename
    >>> x = 5
    >>> typename(x)
    'int'

MIT License

Copyright (c) Sixty North

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/sixty-north/typename",
    "name": "typename",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "Python types typename",
    "author": "Sixty North",
    "author_email": "systems+typename@sixty-north.com",
    "download_url": "https://files.pythonhosted.org/packages/2f/c1/a505c885b63161ea3588baa48ea1a3a664cafc40fe7b784ee15f9558164e/typename-1.0.4.tar.gz",
    "platform": null,
    "description": "# Typename\n\n![CI](https://github.com/sixty-north/typename/actions/workflows/actions.yml/badge.svg)\n\nThe `typename` module defines a single function also called `typename` which returns the name of the\ntype of any object as a string.\n\nIts purpose is purely aesthetic, to avoid unsightly constructs such as `type(obj).__name__` or the\nghastly `obj.__class__.__name__`.\n\n# Installation\n\nThe `typename` package is available on the Python Package Index (PyPI):\n\n[![PyPI version](https://badge.fury.io/py/typename.svg)](https://badge.fury.io/py/typename)\n\n*Typename* should work with any version of Python 3. To install:\n\nWith `pip` from PyPI:\n\n    pip install typename\n\n# How to use\n\n    >>> from typename import typename\n    >>> x = 5\n    >>> typename(x)\n    'int'\n\nMIT License\n\nCopyright (c) Sixty North\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n",
    "bugtrack_url": null,
    "license": "MIT License",
    "summary": "Obtain the name of the type of an object",
    "version": "1.0.4",
    "project_urls": {
        "Homepage": "https://github.com/sixty-north/typename"
    },
    "split_keywords": [
        "python",
        "types",
        "typename"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "29e1b6752e5131f90b47aa618c73e77dd6703e5ddc420851c7b2c1d4306b64db",
                "md5": "e413ddade720c7de9387fd19524a2539",
                "sha256": "ba422aa55026a86632d5c12ac58fff2893fb3dc85e119b3d11cb21a945e7d1ad"
            },
            "downloads": -1,
            "filename": "typename-1.0.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "e413ddade720c7de9387fd19524a2539",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 3672,
            "upload_time": "2023-05-11T08:48:58",
            "upload_time_iso_8601": "2023-05-11T08:48:58.988541Z",
            "url": "https://files.pythonhosted.org/packages/29/e1/b6752e5131f90b47aa618c73e77dd6703e5ddc420851c7b2c1d4306b64db/typename-1.0.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2fc1a505c885b63161ea3588baa48ea1a3a664cafc40fe7b784ee15f9558164e",
                "md5": "19f2694154109694cbe4bfe8a62e8529",
                "sha256": "a3db47d5df84d6667ce23456c7775eb658314c413667549e787f5657e825923f"
            },
            "downloads": -1,
            "filename": "typename-1.0.4.tar.gz",
            "has_sig": false,
            "md5_digest": "19f2694154109694cbe4bfe8a62e8529",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 2986,
            "upload_time": "2023-05-11T08:49:00",
            "upload_time_iso_8601": "2023-05-11T08:49:00.319482Z",
            "url": "https://files.pythonhosted.org/packages/2f/c1/a505c885b63161ea3588baa48ea1a3a664cafc40fe7b784ee15f9558164e/typename-1.0.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-11 08:49:00",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "sixty-north",
    "github_project": "typename",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "typename"
}
        
Elapsed time: 0.21607s