deta / deta-python

deta's official sdk
https://deta.space/docs/en/build/reference/sdk/base
MIT License
153 stars 25 forks source link

What is detalib.app? #49

Closed leits closed 2 years ago

leits commented 3 years ago

https://github.com/deta/deta-python/blob/5d0e5ef6b2ffa319403e55dfcb46ca5daf7410d0/deta/__init__.py#L10-L15

So what is it? 🤔

abdelhai commented 3 years ago

@leits this a simple handler for our cron events: https://docs.deta.sh/docs/micros/cron#code

leits commented 3 years ago

But it means that @app.lib.cron() doesn't work locally and will crash the app 😓

abdelhai commented 3 years ago

Yep. We don't have an elegant way of handling this locally yet.
It's recommended for now to code/debug cron inside a Micro directly.

leits commented 3 years ago

Maybe it's good to add some mocked lib.cron in the client? If you think it's a good idea, I can make a pull request for this feature.

abdelhai commented 3 years ago

@leits I will note this for our next release, maybe we could put App back in the SDK. We need to think about it.

abdelhai commented 2 years ago

detalib will probably disappear soon

eggplants commented 1 year ago

detalib will probably disappear soon

Any updates on this?

lemonyte commented 1 year ago

It will probably be removed in v2, since cron is now handled differently (docs).