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 0C9EE440E3; Fri, 31 May 2024 14:49:23 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D0F27402C9; Fri, 31 May 2024 14:49:22 +0200 (CEST) Received: from mail-ed1-f48.google.com (mail-ed1-f48.google.com [209.85.208.48]) by mails.dpdk.org (Postfix) with ESMTP id 1570040265 for ; Fri, 31 May 2024 14:49:21 +0200 (CEST) Received: by mail-ed1-f48.google.com with SMTP id 4fb4d7f45d1cf-57a196134d1so2204362a12.2 for ; Fri, 31 May 2024 05:49:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pantheon.tech; s=google; t=1717159761; x=1717764561; darn=dpdk.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=seqw9eViQgyPwczsBoTk4tleijOoAi7HSSJUZjn/jrc=; b=uRaLAkPxPq6AT6TmWe4Dc8jAVeK3eojjWCR0gS7ng8uXpwd+oc+Kgz+BegvMjEKRit qMetzM21XELQVPUSLPwaqbRmYup7GzieX0ECxRaCS/UQK2hFTloWdxs/kGAbti+2ugco ZX//0Z+llK0aJOZ5/VcDngvceOosaOD7R27q+/1S0vVqx4FW/fneskOElvUMLpmFfCGy jHJBfrzRu2BmgrhDobF+j2rEjC2f8IAFLvr/WBVAQK4esMqe5l0Zt/x/onyzB/0VWHmh Ls+3Dc7Q72YnM9mV/5am09MPAS1Tuym3p/OgndpOIS/MrsRB1e+8/2xvfvr3YYkhcSMa 1HFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717159761; x=1717764561; h=content-transfer-encoding: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=seqw9eViQgyPwczsBoTk4tleijOoAi7HSSJUZjn/jrc=; b=EUAZqICruXWMmRO5DHPNnrD2czm37KRk+Vnu/81ozqfp9YoxCpEhb0NGXNv9f4cn5K J3O9yK5bFtUPTQbCIZPDhBOc1NVbxd3mqZ/62riJOnHK7YC7Gih4jSk59+VtszK+6N5x RHOAsFLrFB05I/omu+Bc60T1ux5E8IzfZSKD1y2iiTs9BhnWthQ5LP8ijb0b1e21EnN4 qFtiG0hdbARpkBrQkMgmCX5LsV83W2WNOPG28xpmhPigtyxn6cMTtSSs4bIGtOXR2wAk s/RYENVgPr7fWRc3d1IsNElY6Vi1Qr89oefFVAhvGImiK934/oQVENR0pGZjnbq0fs2R GtLQ== X-Gm-Message-State: AOJu0Yz+3r+SC+j3fNtUgFai28YcWeY8IHq5AuTmWaNOqW2GFCjBM27l NbHcB4x0JdVJ6syy2hwzx3Z5VMZJfS6I9ii5ba0MWMF+hUo2MqMyyO11Q5V/O6UbkMAPN1Q+FOy WT22TM6Fr0b0NUgwglNPaxsX2rbcfDaHUWB43qQ== X-Google-Smtp-Source: AGHT+IHXifWNT+6uzmgE/dpLPByXwYT4/jUhVjBmZkVoBkeaYzt1bmcmu//eb3OyWKMI3uZqnnKcX282a1JcpXvywVg= X-Received: by 2002:a50:8e59:0:b0:57a:2ab4:1c6a with SMTP id 4fb4d7f45d1cf-57a364507d3mr1365732a12.32.1717159760144; Fri, 31 May 2024 05:49:20 -0700 (PDT) MIME-Version: 1.0 References: <20240122182611.1904974-1-luca.vizzarro@arm.com> <20240531112042.18736-1-luca.vizzarro@arm.com> <20240531112042.18736-2-luca.vizzarro@arm.com> In-Reply-To: <20240531112042.18736-2-luca.vizzarro@arm.com> From: =?UTF-8?Q?Juraj_Linke=C5=A1?= Date: Fri, 31 May 2024 14:49:09 +0200 Message-ID: Subject: Re: [PATCH v6 1/3] dts: rework arguments framework To: Luca Vizzarro Cc: dev@dpdk.org, Jeremy Spewock , Paul Szczepanek Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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 On Fri, May 31, 2024 at 1:22=E2=80=AFPM Luca Vizzarro wrote: > > The existing argument handling in the code relies on basic argparse > functionality and a custom argparse action to integrate environment > variables. This commit improves the current handling by augmenting > argparse. > > This rework implements the following improvements: > - There are duplicate expressions scattered throughout the code. To > improve readability and maintainability, these are refactored > into list/dict comprehensions or factory functions. > - Instead of relying solely on argument flags, error messages now > accurately reference environment variables when applicable, enhancing > user experience. For instance: > > error: environment variable DTS_DPDK_TARBALL: Invalid file > > - Knowing the number of environment variables and arguments set > allow for a useful help page display when none are provided. > - A display of which environment variables have been detected and their > corresponding values in the help page, aiding user awareness. > > Signed-off-by: Luca Vizzarro > Reviewed-by: Paul Szczepanek Reviewed-by: Juraj Linke=C5=A1