{"id":37073429,"url":"https://github.com/krux/python-krux-scheduler","last_synced_at":"2026-01-14T08:37:09.109Z","repository":{"id":16254752,"uuid":"19002719","full_name":"krux/python-krux-scheduler","owner":"krux","description":"Krux Python class for interacting with APScheduler","archived":true,"fork":false,"pushed_at":"2022-02-11T22:44:36.000Z","size":17,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":84,"default_branch":"master","last_synced_at":"2025-09-22T16:39:17.780Z","etag":null,"topics":["python2"],"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/krux.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null}},"created_at":"2014-04-21T18:44:05.000Z","updated_at":"2023-01-28T03:10:30.000Z","dependencies_parsed_at":"2022-09-13T03:02:12.365Z","dependency_job_id":null,"html_url":"https://github.com/krux/python-krux-scheduler","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/krux/python-krux-scheduler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krux%2Fpython-krux-scheduler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krux%2Fpython-krux-scheduler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krux%2Fpython-krux-scheduler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krux%2Fpython-krux-scheduler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/krux","download_url":"https://codeload.github.com/krux/python-krux-scheduler/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krux%2Fpython-krux-scheduler/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28414667,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T08:31:27.429Z","status":"ssl_error","status_checked_at":"2026-01-14T08:31:19.098Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["python2"],"created_at":"2026-01-14T08:37:08.148Z","updated_at":"2026-01-14T08:37:09.081Z","avatar_url":"https://github.com/krux.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![](https://cdn2.iconfinder.com/data/icons/perfect-flat-icons-2/512/Terminate_wind_up_symbol_stop_send_away_sack.png)\n\n# Deprecated and no longer in use or being maintained.\nThis repo exists as a historical archive.\n\npython-krux-scheduler\n=====================\n\nKrux Python class built on top of [Krux Stdlib](https://staticfiles.krxd.net/foss/docs/pypi/krux-stdlib/) for interacting with [APScheduler](http://pythonhosted.org//APScheduler/)\n\nApplication quick start\n-----------------------\n\nThe most common use case for this library is to run a job periodically from a script.\nTo do that, do the following:\n\n```python\n\nimport time\nfrom krux_scheduler import Application\n\ndef main():\n    ### The name must be unique to the organization. The object\n    ### returned inherits from krux.cli.Application, so it provides\n    ### all that functionality as well.\n    app = Application( name = 'krux-my-periodic-job' )\n\n    ### This is the scheduler object, which behaves exactly\n    ### like an APScheduler object, but with logging, stats\n    ### and CLI support added.\n    scheduler = app.scheduler\n\n    ### define the job you want to run periodically\n    def periodic_job():\n        print 'Called %s at %s' % (app.name, time.asctime())\n\n    ### add the periodic job to the scheduler. This follows\n    ### APSchedulers arguments \u0026 functionality exactly.\n    scheduler.add_cron_job(\n        func   = periodic_job,\n        hour   = '0,8,16'\n        minute = '0',\n    )\n\n    ### start the scheduler\n    scheduler.start()\n\n    ### always call app.exit(), so any clean up that needs to\n    ### happen can be done at the end of your program. It also\n    ### sets the exit code for you appropriately.\n    app.exit()\n\n### Run the application stand alone\nif __name__ == '__main__':\n    main()\n\n```\n\nSeeing it in action\n-------------------\n\nThis library comes with a CLI tool bundled that shows you how the code works.\nIf you run this, it'll alternate between throwing an exception (which is caught)\nand a simple printed message.\n\nThese are the options and how you can invoke it:\n\n```\n$ krux-scheduler-test  -h\nusage: krux-scheduler-test [-h]\n                           [--log-level {info,debug,critical,warning,error}]\n                           [--stats] [--stats-host STATS_HOST]\n                           [--stats-port STATS_PORT]\n                           [--stats-environment STATS_ENVIRONMENT]\n                           [--scheduler-minute SCHEDULER_MINUTE]\n                           [--scheduler-hour SCHEDULER_HOUR]\n                           [--scheduler-daemonize]\n                           [--scheduler-exit-after-job]\n\nkrux-scheduler-test\n\noptional arguments:\n  -h, --help            show this help message and exit\n\nlogging:\n  --log-level {info,debug,critical,warning,error}\n                        Verbosity of logging. (default: warning)\n\nstats:\n  --stats               Enable sending statistics to statsd. (default: False)\n  --stats-host STATS_HOST\n                        Statsd host to send statistics to. (default:\n                        localhost)\n  --stats-port STATS_PORT\n                        Statsd port to send statistics to. (default: 8125)\n  --stats-environment STATS_ENVIRONMENT\n                        Statsd environment. (default: dev)\n\nscheduler:\n  --scheduler-minute SCHEDULER_MINUTE\n                        Comma separated list of minute mark(s) to run on. This\n                        overrides any hardcoded arguments (default: None)\n  --scheduler-hour SCHEDULER_HOUR\n                        Comma separated list of hour mark(s) to run on. This\n                        overrides any hardcoded arguments (default: None)\n  --scheduler-daemonize\n                        Run scheduled jobs in separate threads (default:\n                        False)\n  --scheduler-exit-after-job\n                        Exit the application after a job has completed. Very\n                        useful for RAM hungry applications whose only purpose\n                        is to run a single job but not otherwise. Requires a\n                        process monitor to restart if it exits (default:\n                        False)\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrux%2Fpython-krux-scheduler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkrux%2Fpython-krux-scheduler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrux%2Fpython-krux-scheduler/lists"}