[BUG] function_schema_parser does not support new python union types
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 42/100
Research direction
Locate the function_schema_parser entry point and reproduce the exception with the dataclass examples in this issue. Trace how Optional annotations are handled, then verify that the equivalent Python union annotations are accepted without an exception while existing Optional behavior remains intact.
Written by the indexing model from the issue text.
Description
Similar to https://github.com/palantir/python-compute-module/issues/50
You can't do this:
@dataclass
class ExternalImageSearchResponse:
result: None | external.ImageSearchResponse
error: None | str
You must do this:
@dataclass
class ExternalImageSearchResponse:
result: Optional[external.ImageSearchResponse]
error: Optional[str]
or the parser throws an exception
- Dominant language
- Python
- Stars
- 15
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from palantir/python-compute-module
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 3/5 1-2 days Newbie friendliness 42/100
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
All issues in palantir/python-compute-module
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
anthropics/skills#1811 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
speaches-ai/speaches#678 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
datalayer/mcp-compose#42 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
conda-forge/spacy-feedstock#177 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
UKGovernmentBEIS/inspect_evals#2523 ·