Skip to content

Add support for Async.AwaitEvent #4239

Description

@MangelMaxime
No description provided.

Activity

  1. added a commit that references this issue on Mar 30, 2026
    cd66fbd
  2. github-actions commented on Mar 30, 2026

    @github-actions
    Contributor

    🤖 This is an automated response from Repo Assist.

    Investigation summary

    Async.AwaitEvent was not implemented in the JS/TS runtime library (fable-library-ts/Async.ts). The compiler's Replacements.fs already handles the call site correctly — the asyncs fallthrough maps any unrecognised Async method via Naming.lowerFirst, so AwaitEvent → awaitEvent was already being emitted. Only the runtime function itself was missing.

    Implementation approach

    I've submitted a draft PR (branch repo-assist/fix-issue-4239-async-await-event) that:

    1. Adds awaitEvent<Del, T>(event, cancelAction?) to Async.ts — registers a one-shot handler on the event, resolves the Async(T) when it fires, and removes the handler on cancellation (calling the optional cancelAction before raising OperationCanceledException).
    2. Adds a test case to AsyncTests.fs.

    The implementation follows the same pattern as sleep: uses protectedCont and ctx.cancelToken.addListener for cancellation support.

    Note: This only covers the JS/TS target. Other targets (Python, Dart, Rust, Beam) would need separate runtime implementations.

    Note

    🔒 Integrity filtering filtered 135 items

    Integrity filtering activated and filtered the following items during workflow execution.
    This happens when a tool call accesses a resource that does not meet the required integrity or secrecy level of the workflow.

    • #4393 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4220 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4166 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4143 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4104 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4044 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #4038 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #3290 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #2279 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • #2154 (list_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:Error doesn't show .fs line number #2052 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:Compile Error when referencing another project with EntryPoint #2366 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:simulate this Test Local Machine Timezone to fix this  #2375 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:StackOverflow with Fable but not with fsc in release #2392 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:Inconsistencies with DateTime string formatting #2408 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • issue:Explicit base constructor call not properly called #2425 (list_issues: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".)
    • ... and 119 more items

    Generated by Repo Assist · ◷

    To install this agentic workflow, run

    gh aw add githubnext/agentics/workflows/repo-assist.md@346204513ecfa08b81566450d7d599556807389f
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions