{"id":16148983,"url":"https://github.com/guykisel/python-autocast-decorator","last_synced_at":"2025-03-18T18:33:10.830Z","repository":{"id":23251774,"uuid":"26609784","full_name":"guykisel/python-autocast-decorator","owner":"guykisel","description":"Decorator for automatically casting string inputs to their most likely Python data types.","archived":false,"fork":false,"pushed_at":"2024-10-14T17:35:06.000Z","size":9,"stargazers_count":5,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-10T23:36:44.626Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/guykisel.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-11-13T21:51:55.000Z","updated_at":"2025-02-01T18:54:05.000Z","dependencies_parsed_at":"2024-10-27T18:41:47.033Z","dependency_job_id":null,"html_url":"https://github.com/guykisel/python-autocast-decorator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guykisel%2Fpython-autocast-decorator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guykisel%2Fpython-autocast-decorator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guykisel%2Fpython-autocast-decorator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guykisel%2Fpython-autocast-decorator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/guykisel","download_url":"https://codeload.github.com/guykisel/python-autocast-decorator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243945513,"owners_count":20372895,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-10T00:35:50.381Z","updated_at":"2025-03-18T18:33:10.511Z","avatar_url":"https://github.com/guykisel.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"python-autocast-decorator\n=========================\n\n.. image:: https://travis-ci.org/guykisel/python-autocast-decorator.svg?branch=master\n    :target: https://travis-ci.org/guykisel/python-autocast-decorator/builds\n\nDecorator for automatically casting string inputs to their most likely Python data types.\n\nThis implementation runs ``ast.literal_eval()`` on all inputs. This is simple and reliable, but fairly slow, and therefore probably inappropriate for code that must run fast.\n\nThis decorator uses `wrapt \u003chttps://github.com/GrahamDumpleton/wrapt\u003e`__ to enable signature-preserving decoration.\n\nFor more discussion, see https://stackoverflow.com/questions/7019283/automatically-type-cast-parameters-in-python\n\n.. code:: python\n\n    from autocast import autocast\n    \n    @autocast\n    def my_function(arg):\n        print(type(arg))\n        \n    \u003e\u003e\u003e my_function('3')\n    \u003ctype 'int'\u003e\n\nContribute\n----------\n\nIf you like this module, please contribute! I welcome patches,\ndocumentation, issues, ideas, and so on.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguykisel%2Fpython-autocast-decorator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fguykisel%2Fpython-autocast-decorator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguykisel%2Fpython-autocast-decorator/lists"}