Repository navigation
feat(TaskAutomation): Initial release - #2364
Open
steverobertsuk wants to merge 13 commits into
Open
steverobertsuk wants to merge 13 commits into
steverobertsuk wants to merge 13 commits into
Conversation
Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
Tasks are validated JSON definitions with published revisions; runs pin a revision and keep persistent frames, so they survive API restarts. - One scheduler owns the only timer: a min-heap of jobs, one re-armed timeout, generation guards and bounded draining. - Steps: waits, awaited events, conditions, count/while/until/forever loops, calls, cooperative parallel branches with joins, and the action catalogue (chat, tokens, sides, markers, attributes, pings, effects, jukebox, other-Mod commands and trusted adapters). - Triggers: manual, one-off, fixed-rate/fixed-delay intervals, daily and weekly at a fixed UTC offset, token/attribute/turn order/page/player events, signals and opt-in chat, with cooldown, debounce and burst caps. - Missed work after downtime or pauses follows skip, runOnce, catchUpBounded, review or expire, counted arithmetically. - An action journal reconciles interrupted effects on restart; uncertain non-idempotent effects go to GM review instead of repeating. - GM-only by default, with narrowly published player tasks, effect-time control checks, revision-bound links and single-use confirmations. - A throttled GM dashboard handout, an optional player view and a Help handout; seven worked examples plus the montage fixture as templates. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
Covers the scheduler and heap, expressions, recurrence, the validator and state migrations directly, and runs the built bundle in a Roll20 stub with fake timers for the worked examples, engine behaviour, restart fault injection, permissions, injection and the dashboard. Every end-to-end test asserts that the Mod never held more than one timer. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
scripts/write-schema.mjs generates schema/task-definition.schema.json from the same step catalogue the runtime validator uses. A test checks every example against it with Ajv and fails when the committed file is stale. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
User guide and command reference, task authoring reference, the worked examples with expected results, the recovery and operations guide, the adapter author guide, developer notes, a file map and the live testing checklist. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
Found in live testing on Jumpgate: - Every published task showed "+draft" because the draft's next revision number was compared with the current one. Definitions now track whether the draft has unpublished changes. - Run errors named tokens by ID (-P55Gb… is not a multi-sided token); they now use the token's name. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
Live testing showed TokenMod drops --ids from commands sent by other Mods unless its players-can-ids option is on, so the other-Mod example only shows "sent (not confirmed)" with TokenMod's defaults. The template description, README, worked examples and testing checklist now say so. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
…sync-locales sync-locales used to re-send every string still identical to English on each run. Many are meant to stay English, so Hex (V) and Hex (H) turned into hexadecimal and CRL into a certificate revocation list. It also needed hand-editing all 23 locale files before a reworded English string would be translated again, and sent one request every 2 seconds. - Only strings missing from a locale are translated by default. --untranslated brings back the old behaviour. - --keys a.b,c.d translates the named keys again; unknown keys are an error. - --dry-run lists what would be translated, per locale and key. - --concurrency=N translates N locales at once (default 4); 429s and server errors are retried with back-off. - Placeholder-only strings are not sent, a translation whose placeholders did not survive keeps the English, mask tokens are matched in any case, and files are formatted with the Mod's Prettier settings so unchanged lines stay unchanged. - The estimate before confirming counts the strings to send. The script is now the same file in every Mod. DEVELOPERS.md lists the options. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
… the Journal The Help, Dashboard, Player View and export handouts now use the plain TaskAutomation icon from Roll20's file store as their journal icon (the handout avatar). The icon is set when a handout is created and added to handouts from earlier versions, so existing games get it too. Roll20 stores the avatar as max.webp with a number, so a handout counts as having the icon when its avatar contains the image's path. Only the webp files exist (thumb.png is a 404), so the URL uses thumb.webp. A new ensureHandoutIcon helper in host.js does this wherever a handout is found or created, and createObject gives every new handout the icon. A test covers new handouts and handouts made before. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
The root script and the 1.0.0 snapshot are rebuilt without a version bump and remain identical. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
…he handout Roll20 always stores a handout's journal icon as the full-size file, whatever size the Mod asks for, and shows that file at its natural size at the top of an open handout. The TaskAutomation icon was a 1024 pixel upload, so it filled the handout above the text. The icon now points at a 100 pixel copy of the same artwork. Handouts from earlier builds are matched on the image path, so they change to the small icon the next time the Mod starts. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
The built script and its 1.0.0 copy carry the new icon path. The version number is unchanged. Signed-off-by: Steve Roberts <steve@shadowcomputers.co.uk>
steverobertsuk
force-pushed
the
sr/task-automation-v1-0-0
branch
from
November 11, 2026 23:32
93eeae6 to
c904d56
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Initial release of TaskAutomation
Added
while,untiland GM-approvedforeverloops, calls to other tasks (awaited or detached), parallel branches joined byall,anySuccessorracewith explicit merge rules, variables, signals andstop.skip,runOnce,catchUpBounded,reviewandexpire, counted without replaying every missed time, and incidents with previews and single-use confirmations.allow,skipIfRunning,queue,replace), a circuit breaker, ancestry limits and an emergency stop.TaskAutomation.registerAdapter,registerAction,registerTrigger,emit,signalandstartfor other Mods, with a reference adapter.