{"id":21502417,"url":"https://github.com/jacopodl/powerpy","last_synced_at":"2025-07-15T23:30:29.068Z","repository":{"id":57454451,"uuid":"130739946","full_name":"jacopodl/PowerPy","owner":"jacopodl","description":"A collection of constructs for Python3 :snake::briefcase:","archived":false,"fork":false,"pushed_at":"2018-06-19T10:38:16.000Z","size":35,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-05T16:49:15.891Z","etag":null,"topics":["awesome","library","patterns","python-library","python3"],"latest_commit_sha":null,"homepage":"","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/jacopodl.png","metadata":{"files":{"readme":"README.md","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}},"created_at":"2018-04-23T18:31:42.000Z","updated_at":"2018-06-27T08:52:10.000Z","dependencies_parsed_at":"2022-09-05T05:40:38.561Z","dependency_job_id":null,"html_url":"https://github.com/jacopodl/PowerPy","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacopodl%2FPowerPy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacopodl%2FPowerPy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacopodl%2FPowerPy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jacopodl%2FPowerPy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jacopodl","download_url":"https://codeload.github.com/jacopodl/PowerPy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225924132,"owners_count":17546198,"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":["awesome","library","patterns","python-library","python3"],"created_at":"2024-11-23T18:14:51.972Z","updated_at":"2024-11-23T18:14:52.733Z","avatar_url":"https://github.com/jacopodl.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![CodeFactor](https://www.codefactor.io/repository/github/jacopodl/powerpy/badge)\n\n# PowerPy\nPowerpy is a collection of small functions and classes for Python3, contains an implementation of common patterns and other simple functions to make your life a bit easier.\n\n## Installation\nThe package can be installed through pip:\n\n    $ pip install powerpy\n\nor downloaded from [GitHub](https://github.com/jacopodl/powerpy).\n\n## Examples\nTo implement a simple type checking in your classes:\n```python\nfrom powerpy.type_checking import EnsureTypes\n\nclass Test(EnsureTypes):\n    def __init__(self):\n        self.prop1 = \"\"\n        self.prop2 = 123\n        self.prop3 = None\n\nt=Test()\nt.prop1=\"Hello\" # OK\nt.prop1=123 # Error\nt.prop3 = \"World\" # OK\nt.prop3 = 123 # Ok\n```\nPartial application:\n```python\nfrom powerpy.currying import Currying\n\n@Currying\ndef simple_func(param1, param2):\n    return param1 + param2\n\ns1 = simple_func(\"Hello\")\nprint(s1(\"Alice\")) # HelloAlice\nprint(s1(\"Bob\")) # HelloBob\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacopodl%2Fpowerpy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjacopodl%2Fpowerpy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacopodl%2Fpowerpy/lists"}