Skip to content

fsm.Event(ctx, ...) not work properly with context.WithTimeout() #90

Description

@qiulin

When I use context.WithTimeout(ctx, time.Duration) with fsm.Event(ctx, ...) like:

Callbacks{
			"enter_end": func(ctx context.Context, e *Event) {
				go func() {
					<-ctx.Done()
					enterEndAsyncWorkDone = true
				}()
			},
		},

the internal block exec immediately, not after timeout.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions