{"id":20348459,"url":"https://github.com/saadmairaj/date-time-event","last_synced_at":"2025-07-26T12:10:31.171Z","repository":{"id":62566955,"uuid":"345307531","full_name":"Saadmairaj/date-time-event","owner":"Saadmairaj","description":"A very simple package to trigger events at a specific DateTime.","archived":false,"fork":false,"pushed_at":"2023-02-28T10:29:23.000Z","size":65,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-08T23:44:36.107Z","etag":null,"topics":["date-event","datetime-format","decorator","python","python3","thread","threading","time-event","timer"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/date-time-event/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Saadmairaj.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-03-07T09:37:46.000Z","updated_at":"2024-06-17T13:15:29.000Z","dependencies_parsed_at":"2025-04-12T01:11:08.576Z","dependency_job_id":"fabf21d1-eba6-4967-b57f-862a6b227138","html_url":"https://github.com/Saadmairaj/date-time-event","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Saadmairaj/date-time-event","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Saadmairaj%2Fdate-time-event","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Saadmairaj%2Fdate-time-event/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Saadmairaj%2Fdate-time-event/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Saadmairaj%2Fdate-time-event/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Saadmairaj","download_url":"https://codeload.github.com/Saadmairaj/date-time-event/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Saadmairaj%2Fdate-time-event/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267163749,"owners_count":24045707,"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","status":"online","status_checked_at":"2025-07-26T02:00:08.937Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["date-event","datetime-format","decorator","python","python3","thread","threading","time-event","timer"],"created_at":"2024-11-14T22:20:30.462Z","updated_at":"2025-07-26T12:10:31.149Z","avatar_url":"https://github.com/Saadmairaj.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# date-time-event\n[![PyPI](https://img.shields.io/pypi/v/date-time-event?color=dark)](https://pypi.org/project/date-time-event/)\n[![Codacy Badge](https://app.codacy.com/project/badge/Grade/ee305868a6a044c281f9423102f8480e)](https://www.codacy.com/gh/Saadmairaj/date-time-event/dashboard?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=Saadmairaj/date-time-event\u0026amp;utm_campaign=Badge_Grade)\n[![Codacy Badge](https://app.codacy.com/project/badge/Coverage/ee305868a6a044c281f9423102f8480e)](https://www.codacy.com/gh/Saadmairaj/date-time-event/dashboard?utm_source=github.com\u0026utm_medium=referral\u0026utm_content=Saadmairaj/date-time-event\u0026utm_campaign=Badge_Coverage)\n[![Downloads](https://static.pepy.tech/personalized-badge/date-time-event?period=total\u0026units=international_system\u0026left_color=grey\u0026right_color=brightgreen\u0026left_text=downloads)](https://pepy.tech/project/date-time-event)\n[![Hits](https://hits.seeyoufarm.com/api/count/incr/badge.svg?url=https%3A%2F%2Fgithub.com%2FSaadmairaj%2Fdate-time-event\u0026count_bg=%238EE74A\u0026title_bg=%23555555\u0026icon=python.svg\u0026icon_color=%239A9A9A\u0026title=hits\u0026edge_flat=false)](https://hits.seeyoufarm.com)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FSaadmairaj%2Fdate-time-event.svg?type=small)](https://app.fossa.com/projects/git%2Bgithub.com%2FSaadmairaj%2Fdate-time-event?ref=badge_small)\n\nA very simple package to trigger events at a specific DateTime.\n\n## Installation\n\nUse the package manager pip to install with the following command:\n\n```bash\npip install date-time-event\n```\n\nIf you would like to get the latest master or branch from github, you could also:\n\n```bash\npip install git+https://github.com/Saadmairaj/date-time-event\n```\n\nOr even select a specific revision _(branch/tag/commit)_:\n\n```bash\npip install git+https://github.com/Saadmairaj/date-time-event@master\n```\n\n## Usage\n\nIt is very simple and easy to use. First import the class which can be used either as a decorator or a thread function.\n\n```python\nfrom date_time_event import Untiltime\n```\n\nThe `Untiltime` class is threaded based timer which will wait till the given date or timer is met. As it runs on a separate thread, it doesn't effect the main thread or lock it.\n\n```python\nfrom datetime import datetime, timedelta\nfrom date_time_event import Untiltime\n\n# Current datetime with 5 seconds in future.\ndate = datetime.now() + timedelta(0, 5)\n\n\n@Untiltime(dateOrtime=date)\ndef function():\n    print('Hello! Its time!', datetime.now())\n\n\nfunction()\nprint('Function will be call at: %s \\n' % date)\n```\n\n- `Untiltime` decorator options. Syntax: `@Untiltime( **options )`\n\n  | Options      | Description                                                                                                                                                                                     |\n  | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n  | _function_   | Pass Target function.                                                                                                                                                                           |\n  | _dateOrtime_ | Give date or time for the function to trigger if None give function will be a threaded function which can only run once. The date, time or datetime should be an instance of `datetime` module. |\n  | _name_       | A string used for identification purposes only. Just like in thread                                                                                                                             |\n  | _join_       | Wait until the thread terminates. This blocks the calling thread until the thread whose `join()` method is called terminates.                                                                   |\n  | _group_      | Reserved for future extension when a ThreadGroup class is implemented.                                                                                                                          |\n  | _daemon_     | A boolean value indicating whether this thread is a daemon thread (True) or not (False).                                                                                                        |\n  | _args_       | The _args_ is the argument tuple for the target invocation. Defaults to ().                                                                                                                     |\n  | _kwargs_     | The _kwargs_ is a dictionary of keyword arguments for the target invocation. Defaults to {}.                                                                                                    |\n\nThe `Untiltime` class can also be used as thread class. Like so\n\n```python\nfrom datetime import datetime, timedelta\nfrom date_time_event import Untiltime\n\ndef function():\n    print('Hello! Its time!', datetime.now())\n\n\n# Current datetime with 5 seconds in future.\ndate = datetime.now() + timedelta(0, 5)\n\nth = Untiltime(function, dateOrtime=date)\nth.start()\n\nprint('Function will be call at: %s \\n' % date)\n```\n\nOnce the thread is called it can be stopped or cancel if called `.cancel()` method before the datetime event occurs.\n\n- Set date can be changed with property `date`, if the thread has not started.\n\n    ```python\n    from datetime import datetime, timedelta\n    from date_time_event import Untiltime\n\n    def function():\n        print('Hello! Its time!', datetime.now())\n\n\n    # Current datetime with 2 seconds in future.\n    date = datetime.now() + timedelta(0, 2)\n\n    th = Untiltime(function, dateOrtime=date)\n    # Initializing new date with 5 seconds in future\n    th.date = datetime.now() + timedelta(0, 5)\n    th.start()\n\n    print('Function will be call at: %s \\n' % th.date)\n    ```\n\n## [License](https://github.com/Saadmairaj/date-time-event/blob/master/LICENSE) \n\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FSaadmairaj%2Fdate-time-event.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2FSaadmairaj%2Fdate-time-event?ref=badge_large)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaadmairaj%2Fdate-time-event","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaadmairaj%2Fdate-time-event","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaadmairaj%2Fdate-time-event/lists"}