Decorators with def main() not working in python
Wondering if this is windmill runtime specific config issue? It works well if I use the decorator on any other method and call it inside main.
See below the code:
error:
ExecutionErr: error during execution of the script:
Error parsing code: Got unexpected EOF at byte offset 617def my_decorator(func):
def wrapper():
print("Something is happening before the function is called.")
func()
print("Something is happening after the function is called.")
return wrapper
@my_decorator
def main():
print("The main function is running.")There are now many ways to pass specific context to the AIChat for full-code apps. You can use the inspector in the preview, select lines in the editor, use @ mentions (which works with datatables, backend runnables and frontend runnables)
rubenf ยท 5d ago
**Full-code apps local development in alpha with datatables and any local AI agents ** For the most adventurous of you, in 1.599.0 you can build raw apps fully locally and windmill will take care of providing enough contexts for an agent like Claude to use datatables for storage when initialized with `wmill app new` . Use `wmill app dev` in the app folder to generate a live preview that will also allow you to apply datatables migrations generated by the agents to generate any datatable needed. Highly recommend setting datatable in your workspace settings for the full experience. Require both an updated CLI and windmill. https://www.youtube.com/watch?v=hNQCmpehE2w Merry christmas ๐
rubenf ยท 7d ago
little surprise to discover on latest ๐ It's early, it works especially well with AI and the new data tables. We're eager for your feedback
rubenf ยท 2w ago