qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eduardo Habkost <ehabkost@redhat.com>
To: Aleksandar Markovic <aleksandar.m.mail@gmail.com>
Cc: "pburton@wavecomp.com" <pburton@wavecomp.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	Filip Bozuta <Filip.Bozuta@rt-rk.com>,
	"hpoussin@reactos.org" <hpoussin@reactos.org>,
	"amarkovic@wavecomp.com" <amarkovic@wavecomp.com>,
	Cleber Rosa <crosa@redhat.com>,
	"aleksandar.rikalo@rt-rk.com" <aleksandar.rikalo@rt-rk.com>,
	"aurelien@aurel32.net" <aurelien@aurel32.net>
Subject: Re: [PATCH 2/5] mips: malta: Renovate coding style
Date: Mon, 2 Dec 2019 17:49:58 -0300	[thread overview]
Message-ID: <20191202204958.GP14595@habkost.net> (raw)
In-Reply-To: <CAL1e-=jeECJRjOR+Mo79D5VA8q0gSZsf__MOtRhiU0fgDF1DRA@mail.gmail.com>

On Sun, Dec 01, 2019 at 12:46:12AM +0100, Aleksandar Markovic wrote:
> On Monday, November 25, 2019, Filip Bozuta <Filip.Bozuta@rt-rk.com> wrote:
> 
> > The script checkpatch.pl located in scripts folder was
> > used to detect all errors and warrnings in files:
> >     hw/mips/mips_malta.c
> >     hw/mips/gt64xxx_pci.c
> >     tests/acceptance/linux_ssh_mips_malta.py
> >
> > All these mips malta machine files were edited and
> > all the errors and warrings generated by the checkpatch.pl
> > script were corrected and then the script was
> > ran again to make sure there are no more errors and warnings.
> >
> > Signed-off-by: Filip Bozuta <Filip.Bozuta@rt-rk.com>
> > ---
> >  hw/mips/mips_malta.c                     | 139
> > ++++++++++++++++---------------
> >  tests/acceptance/linux_ssh_mips_malta.py |   6 +-
> >  2 files changed, 75 insertions(+), 70 deletions(-)
> >
> >
> Very good cleanup!
> 
> Reviewed-by: Aleksandar Markovic <amarkovic@wavecomp.com>
> 
> I think this snippet is good, but I am just in case cc-ing Cleber and
> Eduardo to check if it is in accordance with any applicable guidelines of
> our test framework:

Thanks for CCing us.

> 
> 
> > diff --git a/tests/acceptance/linux_ssh_mips_malta.py
> > b/tests/acceptance/linux_ssh_mips_malta.py
> > index fc13f9e..44e1118 100644
> > --- a/tests/acceptance/linux_ssh_mips_malta.py
> > +++ b/tests/acceptance/linux_ssh_mips_malta.py
> > @@ -99,10 +99,12 @@ class LinuxSSH(Test):
> >      def ssh_command(self, command, is_root=True):
> >          self.ssh_logger.info(command)
> >          result = self.ssh_session.cmd(command)
> > -        stdout_lines = [line.rstrip() for line in
> > result.stdout_text.splitlines()]
> > +        stdout_lines = [line.rstrip() for line
> > +        in result.stdout_text.splitlines()]
> >          for line in stdout_lines:
> >              self.ssh_logger.info(line)
> > -        stderr_lines = [line.rstrip() for line in
> > result.stderr_text.splitlines()]
> > +        stderr_lines = [line.rstrip() for line
> > +        in result.stderr_text.splitlines()]

If you really want to split those lines, please indent them
properly.  e.g.:

        stdout_lines = [line.rstrip() for line
                        in result.stdout_text.splitlines()]

See PEP 8 [1] for additional examples.

Personally, I would just keep the existing
linux_ssh_mips_malta.py code as is.  I don't think splitting
those lines improves readability.

[1] https://www.python.org/dev/peps/pep-0008/#indentation

-- 
Eduardo



  reply	other threads:[~2019-12-02 20:51 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-25 13:04 [PATCH 0/5] mips: machines: Renovate coding style Filip Bozuta
2019-11-25 13:04 ` [PATCH 1/5] mips: jazz: " Filip Bozuta
2019-12-06  8:07   ` Aleksandar Markovic
2019-11-25 13:04 ` [PATCH 2/5] mips: malta: " Filip Bozuta
2019-11-30 23:46   ` Aleksandar Markovic
2019-12-02 20:49     ` Eduardo Habkost [this message]
2019-12-05 21:27       ` Cleber Rosa
2019-12-06  8:24         ` Aleksandar Markovic
2019-12-01  0:00   ` Aleksandar Markovic
2019-12-01 20:20   ` Philippe Mathieu-Daudé
2019-12-06  8:21     ` Aleksandar Markovic
2019-11-25 13:04 ` [PATCH 3/5] mips: mipssim: " Filip Bozuta
2019-12-06  8:03   ` Aleksandar Markovic
2019-11-25 13:04 ` [PATCH 4/5] mips: r4000: " Filip Bozuta
2019-12-02  0:08   ` Aleksandar Markovic
2019-11-25 13:04 ` [PATCH 5/5] mips: fulong 2e: " Filip Bozuta
2019-12-01 23:49   ` Aleksandar Markovic
2019-12-06 13:58 [PATCH 0/5] mips: machines: " Filip Bozuta
2019-12-06 13:58 ` [PATCH 2/5] mips: malta: " Filip Bozuta

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:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

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

  git send-email \
    --in-reply-to=20191202204958.GP14595@habkost.net \
    --to=ehabkost@redhat.com \
    --cc=Filip.Bozuta@rt-rk.com \
    --cc=aleksandar.m.mail@gmail.com \
    --cc=aleksandar.rikalo@rt-rk.com \
    --cc=amarkovic@wavecomp.com \
    --cc=aurelien@aurel32.net \
    --cc=crosa@redhat.com \
    --cc=hpoussin@reactos.org \
    --cc=pburton@wavecomp.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* 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).