Skip to content

[Bug] Pyright typing issue #795

Open
@mattbrandman

Description

@mattbrandman

What are you really trying to do?

Ensure that my type checking returns minimal errors when using temporal execute_activity

Describe the bug

Type checking with Pyright strict returns partiallyUnknown error when using Temporal execute_activity I believe because the line here

result_type: Optional[Type] = None,
has an implicit Any on the optional Type

Adding an explicit Any allows Pyright to properly parse the block

Minimal Reproduction

Look at any execute_activity call in the samples repo with Pyright strict enabled in VSCode

Environment/Versions

  • OS and processor: [e.g. M1 Mac, x86 Windows, Linux]
  • Temporal Version: [e.g. 1.14.0?] and/or SDK version
  • Are you using Docker or Kubernetes or building Temporal from source?

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions