{"id":16270123,"url":"https://github.com/ealmloff/functional-python","last_synced_at":"2025-04-08T15:23:17.249Z","repository":{"id":110688128,"uuid":"314916710","full_name":"ealmloff/functional-python","owner":"ealmloff","description":"A python decorator that enforces functional programming within a function.","archived":false,"fork":false,"pushed_at":"2020-11-22T01:27:02.000Z","size":19,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-14T11:51:24.112Z","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":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ealmloff.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,"governance":null}},"created_at":"2020-11-21T22:41:43.000Z","updated_at":"2020-11-22T01:27:04.000Z","dependencies_parsed_at":"2023-08-24T21:25:41.736Z","dependency_job_id":null,"html_url":"https://github.com/ealmloff/functional-python","commit_stats":null,"previous_names":["ealmloff/functional-python"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ealmloff%2Ffunctional-python","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ealmloff%2Ffunctional-python/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ealmloff%2Ffunctional-python/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ealmloff%2Ffunctional-python/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ealmloff","download_url":"https://codeload.github.com/ealmloff/functional-python/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247867841,"owners_count":21009330,"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-10T18:09:44.980Z","updated_at":"2025-04-08T15:23:17.229Z","avatar_url":"https://github.com/ealmloff.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# functional-python\nA python decorator that enforces functional programming within a function.\n\nThe decorator requires the function to use no global variables unless the variables are all caps or builtin to python.\nThe decorator accepts a boolean value to signify weither or not caching should be implemented\n\nExample:\n\nfrom math import pi\nfrom functional import functional\n\nSTATIC_GLOBAL_VAR = 100\nnonStaticGlobal = -100\n\n@functional()\ndef goodFunction(): # will not raise an exception\n    global STATIC_GLOBAL_VAR\n    STATIC_GLOBAL_VAR -= 1\n    print(STATIC_GLOBAL_VAR)\n    print(print)\n\ngoodFunction()\n\n@functional()\ndef badFunction(): # will raise an exception\n    global nonStaticGlobal\n    nonStaticGlobal -= 1\n    print(nonStaticGlobal)\n\nbadFunction()\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fealmloff%2Ffunctional-python","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fealmloff%2Ffunctional-python","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fealmloff%2Ffunctional-python/lists"}