google / google/dotprompt

Decide on error handling for None resolver returns and list-only frontmatter

Open
#496 0 comments 0 reactions 0 assignees View on GitHub
python question
Dominant language
Starlark
Stars
563
Forks
68
Avg merge
6m
Merged PRs (30d)
2

Description

## Summary

There are open questions about error handling in the Python implementation:

1. Should the resolver raise LookupError when it returns None?
2. Should list-only frontmatter (no key-value pairs) be an error?

## Locations

- `python/dotpromptz/src/dotpromptz/resolvers.py:146`: `# TODO: Should we raise a LookupError if the resolver returns None?`
- `python/dotpromptz/src/dotpromptz/parse.py:277`: `# TODO: Should this be an error?`

## Acceptance Criteria

- [ ] Document expected behavior in spec
- [ ] Implement consistent error handling across runtimes
- [ ] Add tests for edge cases

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.