archive mirror
 help / color / mirror / Atom feed
From: David Gow <>
To: Daniel Latypov <>
Cc: Brendan Higgins <>,
	Linux Kernel Mailing List <>,
	Shuah Khan <>
Subject: Re: [PATCH 1/3] kunit: tool: surface and address more typing issues
Date: Fri, 4 Dec 2020 13:50:29 +0800	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On Fri, Dec 4, 2020 at 3:41 AM Daniel Latypov <> wrote:
> The authors of this tool were more familiar with a different
> type-checker,
> That's open source, but mypy seems more prevalent (and runs faster).
> And unlike pytype, mypy doesn't try to infer types so it doesn't check
> unanotated functions.
> So annotate ~all functions in kunit tool to increase type-checking
> coverage.
> Note: per, `__init__()` should
> be annotated as `-> None`.
> Doing so makes mypy discover a number of new violations.
> Exclude main() since we reuse `request` for the different types of
> requests, which mypy isn't happy about.
> This commit fixes all but one error, where `TestSuite.status` might be
> None.
> Signed-off-by: Daniel Latypov <>
> ---

This looks good to me: I gave it some quick testing, and reading
through it, all of the changes seem sensible.

I wasn't able to get pytype running here, but mypy worked fine.

Reviewed-by: David Gow <>

-- David

      parent reply	other threads:[~2020-12-04  5:51 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-03 19:41 [PATCH 1/3] kunit: tool: surface and address more typing issues Daniel Latypov
2020-12-03 19:41 ` [PATCH 2/3] kunit: tool: fix minor typing issue with None status Daniel Latypov
2020-12-04  4:16   ` David Gow
2020-12-04 18:08     ` Daniel Latypov
2020-12-03 19:41 ` [PATCH 3/3] kunit: tool: move kunitconfig parsing into __init__ Daniel Latypov
2020-12-04  3:57   ` David Gow
2020-12-04 18:18     ` Daniel Latypov
2020-12-05  5:04       ` David Gow
2020-12-04  5:50 ` David Gow [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).