temporalio / temporalio/sdk-python

[Bug] Add ability to obtain `ApplicationError` details with type hint

Open
#1,262 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
1.2k
Forks
241
Avg merge
3d 21h
Merged PRs (30d)
55

Description

Describe the bug

For users of deserialized ApplicationError, today we only offer the deserialized details in raw Python form (e.g. dicts and such). For ApplicationErrors that are deserialized, we should make the details property lazy, have a property for obtaining the raw details (that only works if raw details were set on create, i.e. in deserialization situations), and have a method that lets you access a detail by index and type hint.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the ApplicationError implementation and trace its deserialization path. Work out how lazy details, raw details when available, and indexed access with a type hint should coexist. Done means deserialized errors expose the requested access patterns without losing the existing raw Python details behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend-api-design
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.