mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-25 08:00:59 +00:00
add data tables comment to scheduled poll templates (#8221)
Add a comment to each scheduled poll template (Python, Deno, Bun, Go) mentioning that data tables can be used for more complex states, with a link to the documentation. Closes #8220 Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com> Co-authored-by: windmill-internal-app[bot] <windmill-internal-app[bot]@users.noreply.github.com>
This commit is contained in:
@@ -30,6 +30,9 @@ def main():
|
||||
# wmill.setState(newState)
|
||||
# 4. Return the new rows
|
||||
# return range from (state to newState)
|
||||
#
|
||||
# For more complex states, consider using Data Tables:
|
||||
# https://www.windmill.dev/docs/core_concepts/persistent_storage/data_tables
|
||||
return [1, 2, 3]`
|
||||
|
||||
const PYTHON_INIT_CODE = `import os
|
||||
@@ -554,6 +557,9 @@ export async function main() {
|
||||
// await wmill.setState(newState)
|
||||
// 4. Return the new rows
|
||||
// return range from (state to newState)
|
||||
//
|
||||
// For more complex states, consider using Data Tables:
|
||||
// https://www.windmill.dev/docs/core_concepts/persistent_storage/data_tables
|
||||
|
||||
return [1,2,3]
|
||||
|
||||
@@ -575,6 +581,9 @@ export async function main() {
|
||||
// await wmill.setState(newState)
|
||||
// 4. Return the new rows
|
||||
// return range from (state to newState)
|
||||
//
|
||||
// For more complex states, consider using Data Tables:
|
||||
// https://www.windmill.dev/docs/core_concepts/persistent_storage/data_tables
|
||||
|
||||
return [1,2,3]
|
||||
|
||||
@@ -599,6 +608,9 @@ func main() (interface{}, error) {
|
||||
// 3. Compare the two states and update the internal state
|
||||
wmill.SetState(4)
|
||||
// 4. Return the new rows
|
||||
//
|
||||
// For more complex states, consider using Data Tables:
|
||||
// https://www.windmill.dev/docs/core_concepts/persistent_storage/data_tables
|
||||
|
||||
return state, nil
|
||||
|
||||
|
||||
Reference in New Issue
Block a user