aws / aws/chalice

Unable to run cron in local

Open
#979 9 comments 17 reactions 0 assignees View on GitHub
feature-request
Dominant language
Python
Stars
11.1k
Forks
1k
Avg merge
1d 22h
Merged PRs (30d)
2

Description

I'm trying to write a chalice app for scheduled events.

```
import logging
from chalice import Chalice
from chalice.app import Cron

app = Chalice(app_name='import_blogs')
# Enable DEBUG logs.
app.log.setLevel(logging.DEBUG)

@app.schedule(Cron('*/2', '*', '*', '*', '?', '*'))
def import_rss(event):
app.log.debug('Inside import_rss')
return {'hello': 'rss'}
```

I expect the log to be printed every two minutes when running `chalice local`. However, there is no output.

Is there a way to simulate Cloudwatch scheduled events in local development, without deploying to lambda?

Contributor guide

Open the contributing guide

Research direction

Start with the chalice local entry point and the @app.schedule(Cron(...)) usage shown in the issue, then trace how scheduled events are handled during local development. Determine whether local execution should simulate CloudWatch scheduled events without deployment; done means an agreed implementation or documented supported workflow, with coverage for the demonstrated cron expression.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, python
Domain
backend, cloud
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.