From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4A36A43C49; Mon, 13 May 2024 18:03:02 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CA7EC406B6; Mon, 13 May 2024 18:02:13 +0200 (CEST) Received: from mail-ed1-f51.google.com (mail-ed1-f51.google.com [209.85.208.51]) by mails.dpdk.org (Postfix) with ESMTP id 6AF32402CD for ; Mon, 13 May 2024 18:02:12 +0200 (CEST) Received: by mail-ed1-f51.google.com with SMTP id 4fb4d7f45d1cf-572c65cea55so8050794a12.0 for ; Mon, 13 May 2024 09:02:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pantheon.tech; s=google; t=1715616132; x=1716220932; darn=dpdk.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=fZEk8+N6+eCEmR5FWVNxEOMyWv50zczQ3+2KTnve9xs=; b=fqDa8BVMZ47RCa2qDe9H5WXrQTbEuorGYWL/o86dcq9+EzmBlsFZpV6a0SkMpvi6Mf ouaaDwCEPepRezQU+rWOKpI34fYIDVHDECfLsa+Vyc8vRfA2S41dvWNm1tASzKE7+FW/ v2CuZVcEqMizq6mj/70E7j2EXlROscn08+X52ff9EJAK2ZUi3JlqIYM1DKMdzhtnRc7E j/4N4g8blGwDwpgaRBvn8h5fUd+B00MzVnwFGxlVFByD/7zaQ0mvJaJ9u16M7srXp+Oq 4gCbCQmwaoQIUd+Xr+f+37//4uuU9KD7R0bBXj9DRNkltGaZI77C+rZsJfUoNxH/XZWb RR5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715616132; x=1716220932; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=fZEk8+N6+eCEmR5FWVNxEOMyWv50zczQ3+2KTnve9xs=; b=sVXFcb7vHkoOIYB+PHOKRgwqBZMoozi9v/OjpjD/ZYFg23pvroeGrGsdunp3a4xgEA jno2qIOVRbBySFPQB0CwSZHmSQC16+Miuq8Pwh/sF1WRwDhe9XlOS3AL2jEvzyXHCLvn BAsi+B0kibaRuX9zVKaBLLu4OMJ8yIdpNxt2VCmYDkKJu+y0S2fWytJ/v6qnzfotV1td QRtTbhRoNV5o68kTfJo4Ph539ChY3Vf0cMdPp4Cpe0A/XRZyZy/p3MfSCKKvL/5+u4tj 8Uz9neta5lSquulHXFMH4i23cq4fjnD5YzBjbnL9/KIvbFi1h6rYiK5jRI7aR92zBePz OZEg== X-Gm-Message-State: AOJu0YyRQYGQUF8kOcmoVnSC2ssh69wWiRElJOu4dIeFJePE9S5Fhs0Y OE+Isp1O9CaI2giKcbUlU+V7eg4iNtulTDk4kzFc2jInUEs5ZQafOr88to2Lo+1rKZL7pdqFI5Y 0+41hlr/aZhKjI+k0+YWH5dGYMLLKDnXT7blWlw== X-Google-Smtp-Source: AGHT+IFrfWtKG/lfj2SsOaSzFOqOxRCxe+Xe/ZVhYiYNptp+hEr8vpJ4TKx6ZDD4bsrn46C1A8YI1Xyh2zP8qfqxPDg= X-Received: by 2002:aa7:c485:0:b0:572:7d77:179d with SMTP id 4fb4d7f45d1cf-573326edde8mr9946968a12.5.1715616132075; Mon, 13 May 2024 09:02:12 -0700 (PDT) MIME-Version: 1.0 References: <20240509105704.1162449-1-luca.vizzarro@arm.com> <20240509105704.1162449-2-luca.vizzarro@arm.com> In-Reply-To: <20240509105704.1162449-2-luca.vizzarro@arm.com> From: =?UTF-8?Q?Juraj_Linke=C5=A1?= Date: Mon, 13 May 2024 18:02:01 +0200 Message-ID: Subject: Re: [PATCH 1/2] dts: update mypy static checker To: Luca Vizzarro Cc: dev@dpdk.org, Jeremy Spewock , Paul Szczepanek Content-Type: text/plain; charset="UTF-8" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > diff --git a/dts/framework/runner.py b/dts/framework/runner.py > index db8e3ba96b..d74f1871db 100644 > --- a/dts/framework/runner.py > +++ b/dts/framework/runner.py > @@ -23,7 +23,7 @@ > import re > import sys > from pathlib import Path > -from types import MethodType > +from types import FunctionType > from typing import Iterable, Sequence > > from .config import ( > @@ -132,8 +132,8 @@ def run(self): > the :option:`--test-suite` command line argument or > the :envvar:`DTS_TESTCASES` environment variable. > """ > - sut_nodes: dict[str, SutNode] = {} > - tg_nodes: dict[str, TGNode] = {} > + sut_nodes = {} > + tg_nodes = {} > try: > # check the python version of the server that runs dts > self._check_dts_python_version() > @@ -305,7 +305,7 @@ def is_test_suite(object) -> bool: > > def _filter_test_cases( > self, test_suite_class: type[TestSuite], test_cases_to_run: Sequence[str] > - ) -> tuple[list[MethodType], list[MethodType]]: > + ) -> tuple[list[FunctionType], list[FunctionType]]: Does changing inspect.getmembers(test_suite_class, inspect.isfunction) to use inspect.ismethod not work? > """Filter `test_cases_to_run` from `test_suite_class`. > > There are two rounds of filtering if `test_cases_to_run` is not empty.