Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GH-99: include types and check types #1224

Conversation

ChristianMurphy
Copy link

@ChristianMurphy ChristianMurphy commented Dec 12, 2024

builds on: GH-1223
resolves: GH-99
source: https://safjan.com/the-importance-of-adding-py-typed-file-to-your-typed-package/

note:
The types aren't currently checks so it is expected that there are some errors in the type check task.
Adding this as a check is a step towards making the types valid, and they can be progressively updated until the check does pass.

Copy link

vercel bot commented Dec 12, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
evals-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 12, 2024 6:09pm

@penguine-ip
Copy link
Contributor

@ChristianMurphy tbh i''m not too sure what this is so i'm afriad of merging it, will close this for now

@ChristianMurphy
Copy link
Author

@penguine-ip the goal is to support https://docs.python.org/3/library/typing.html so that consumers of this library using get typeahead competition when using the deepeval API in an IDE, and can validate they are using the types correctly with a checker like https://www.mypy-lang.org/, https://github.com/microsoft/pyright, or https://github.com/facebook/pyre-check

To do that this project needs to:

  1. Pick a packaging tool (there are several in the code right now ans its unclear which actually publishes), I'd recommend poetry GH-1169: sync dependencies between setup py and pyproject toml, remove setup py #1223 or UV, but am open to maintainer suggestions .
  2. For that package manager include a py.typed file https://safjan.com/the-importance-of-adding-py-typed-file-to-your-typed-package/ so downstream packages know to look for types
  3. (Optional) check the internal code and tests with a type checker to ensure the types shared are accurate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve typing (Mypy) support
2 participants