facebook / facebook/TestSlide

Simplify typehints

未关闭
#248 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
easy enhancement good first issue help wanted
主要语言
Python
星标
149
派生
62
PR 合并指标
30 天内没有已合并 PR

描述

As per @fornellas comments on #246 do these:
- Unions of BaseException & other exception types (eg: Exception). Shouldn't BaseException be enough? All Python exception are subclasses of it, I think it should work just fine with only it.

- There are lots of Callable types (no args, no return) or Callable[[a,b,c...], d], mostly related to DSL hooks, such as examples, before / after hooks etc. TBH, this PR is awesome as it is, but I was thinking about having custom types such as ExampleFunction = Callable[[_ContextData], None] (non-blocking here to be clear).

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。