All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] scripts: More Python fixes
@ 2020-05-12  7:06 Philippe Mathieu-Daudé
  2020-05-12  7:06 ` [PATCH v3 1/2] scripts/qemugdb: Remove shebang header Philippe Mathieu-Daudé
  2020-05-12  7:06 ` [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter Philippe Mathieu-Daudé
  0 siblings, 2 replies; 6+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-12  7:06 UTC (permalink / raw)
  To: qemu-devel
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Philippe Mathieu-Daudé,
	Markus Armbruster, Philippe Mathieu-Daudé,
	John Snow, Stefan Hajnoczi, Cleber Rosa, Alex Bennée

Trivial Python3 fixes, again...

Since v2:
- Remove patch updating MAINTAINERS

Since v1:
- Added Alex Bennée A-b tags
- Addressed John Snow review comments
  - Use /usr/bin/env
  - Do not modify os.path (dropped last patch)

Philippe Mathieu-Daudé (2):
  scripts/qemugdb: Remove shebang header
  scripts/qmp: Use Python 3 interpreter

 scripts/qemugdb/__init__.py  | 3 +--
 scripts/qemugdb/aio.py       | 3 +--
 scripts/qemugdb/coroutine.py | 3 +--
 scripts/qemugdb/mtree.py     | 4 +---
 scripts/qemugdb/tcg.py       | 1 -
 scripts/qmp/qom-get          | 2 +-
 scripts/qmp/qom-list         | 2 +-
 scripts/qmp/qom-set          | 2 +-
 scripts/qmp/qom-tree         | 2 +-
 9 files changed, 8 insertions(+), 14 deletions(-)

-- 
2.21.3



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH v3 1/2] scripts/qemugdb: Remove shebang header
  2020-05-12  7:06 [PATCH v3 0/2] scripts: More Python fixes Philippe Mathieu-Daudé
@ 2020-05-12  7:06 ` Philippe Mathieu-Daudé
  2020-05-12  8:55   ` Kevin Wolf
  2020-05-12  7:06 ` [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter Philippe Mathieu-Daudé
  1 sibling, 1 reply; 6+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-12  7:06 UTC (permalink / raw)
  To: qemu-devel
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Philippe Mathieu-Daudé,
	Markus Armbruster, Philippe Mathieu-Daudé,
	John Snow, Stefan Hajnoczi, Cleber Rosa, Alex Bennée

These scripts are loaded as plugin by GDB (and they don't
have any __main__ entry point). Remove the shebang header.

Acked-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 scripts/qemugdb/__init__.py  | 3 +--
 scripts/qemugdb/aio.py       | 3 +--
 scripts/qemugdb/coroutine.py | 3 +--
 scripts/qemugdb/mtree.py     | 4 +---
 scripts/qemugdb/tcg.py       | 1 -
 5 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/scripts/qemugdb/__init__.py b/scripts/qemugdb/__init__.py
index 969f552b26..da8ff612e5 100644
--- a/scripts/qemugdb/__init__.py
+++ b/scripts/qemugdb/__init__.py
@@ -1,5 +1,4 @@
-#!/usr/bin/python
-
+#
 # GDB debugging support
 #
 # Copyright (c) 2015 Linaro Ltd
diff --git a/scripts/qemugdb/aio.py b/scripts/qemugdb/aio.py
index 2ba00c4444..d7c1ba0c28 100644
--- a/scripts/qemugdb/aio.py
+++ b/scripts/qemugdb/aio.py
@@ -1,5 +1,4 @@
-#!/usr/bin/python
-
+#
 # GDB debugging support: aio/iohandler debug
 #
 # Copyright (c) 2015 Red Hat, Inc.
diff --git a/scripts/qemugdb/coroutine.py b/scripts/qemugdb/coroutine.py
index 41e079d0e2..db61389022 100644
--- a/scripts/qemugdb/coroutine.py
+++ b/scripts/qemugdb/coroutine.py
@@ -1,5 +1,4 @@
-#!/usr/bin/python
-
+#
 # GDB debugging support
 #
 # Copyright 2012 Red Hat, Inc. and/or its affiliates
diff --git a/scripts/qemugdb/mtree.py b/scripts/qemugdb/mtree.py
index 3030a60d3f..8fe42c3c12 100644
--- a/scripts/qemugdb/mtree.py
+++ b/scripts/qemugdb/mtree.py
@@ -1,5 +1,4 @@
-#!/usr/bin/python
-
+#
 # GDB debugging support
 #
 # Copyright 2012 Red Hat, Inc. and/or its affiliates
@@ -84,4 +83,3 @@ def print_item(self, ptr, offset = gdb.Value(0), level = 0):
         while not isnull(subregion):
             self.print_item(subregion, addr, level)
             subregion = subregion['subregions_link']['tqe_next']
-
diff --git a/scripts/qemugdb/tcg.py b/scripts/qemugdb/tcg.py
index 18880fc9a7..16c03c06a9 100644
--- a/scripts/qemugdb/tcg.py
+++ b/scripts/qemugdb/tcg.py
@@ -1,4 +1,3 @@
-#!/usr/bin/python
 # -*- coding: utf-8 -*-
 #
 # GDB debugging support, TCG status
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter
  2020-05-12  7:06 [PATCH v3 0/2] scripts: More Python fixes Philippe Mathieu-Daudé
  2020-05-12  7:06 ` [PATCH v3 1/2] scripts/qemugdb: Remove shebang header Philippe Mathieu-Daudé
@ 2020-05-12  7:06 ` Philippe Mathieu-Daudé
  2020-05-12  8:57   ` Kevin Wolf
  1 sibling, 1 reply; 6+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-12  7:06 UTC (permalink / raw)
  To: qemu-devel
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Philippe Mathieu-Daudé,
	Markus Armbruster, Philippe Mathieu-Daudé,
	John Snow, Stefan Hajnoczi, Cleber Rosa, Alex Bennée

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 scripts/qmp/qom-get  | 2 +-
 scripts/qmp/qom-list | 2 +-
 scripts/qmp/qom-set  | 2 +-
 scripts/qmp/qom-tree | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/scripts/qmp/qom-get b/scripts/qmp/qom-get
index 007b4cd442..7c5ede91bb 100755
--- a/scripts/qmp/qom-get
+++ b/scripts/qmp/qom-get
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python3
 ##
 # QEMU Object Model test tools
 #
diff --git a/scripts/qmp/qom-list b/scripts/qmp/qom-list
index 03bda3446b..bb68fd65d4 100755
--- a/scripts/qmp/qom-list
+++ b/scripts/qmp/qom-list
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python3
 ##
 # QEMU Object Model test tools
 #
diff --git a/scripts/qmp/qom-set b/scripts/qmp/qom-set
index c37fe78b00..19881d85e9 100755
--- a/scripts/qmp/qom-set
+++ b/scripts/qmp/qom-set
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python3
 ##
 # QEMU Object Model test tools
 #
diff --git a/scripts/qmp/qom-tree b/scripts/qmp/qom-tree
index 1c8acf61e7..fa91147a03 100755
--- a/scripts/qmp/qom-tree
+++ b/scripts/qmp/qom-tree
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/env python3
 ##
 # QEMU Object Model test tools
 #
-- 
2.21.3



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] scripts/qemugdb: Remove shebang header
  2020-05-12  7:06 ` [PATCH v3 1/2] scripts/qemugdb: Remove shebang header Philippe Mathieu-Daudé
@ 2020-05-12  8:55   ` Kevin Wolf
  2020-05-12 10:33     ` Philippe Mathieu-Daudé
  0 siblings, 1 reply; 6+ messages in thread
From: Kevin Wolf @ 2020-05-12  8:55 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Alex Bennée, qemu-devel, Markus Armbruster, Stefan Hajnoczi,
	Cleber Rosa, Philippe Mathieu-Daudé

Am 12.05.2020 um 09:06 hat Philippe Mathieu-Daudé geschrieben:
> These scripts are loaded as plugin by GDB (and they don't
> have any __main__ entry point). Remove the shebang header.
> 
> Acked-by: Alex Bennée <alex.bennee@linaro.org>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
>  scripts/qemugdb/__init__.py  | 3 +--
>  scripts/qemugdb/aio.py       | 3 +--
>  scripts/qemugdb/coroutine.py | 3 +--
>  scripts/qemugdb/mtree.py     | 4 +---
>  scripts/qemugdb/tcg.py       | 1 -

There is still a shebang line left in scripts/qemugdb/timers.py.

Kevin



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter
  2020-05-12  7:06 ` [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter Philippe Mathieu-Daudé
@ 2020-05-12  8:57   ` Kevin Wolf
  0 siblings, 0 replies; 6+ messages in thread
From: Kevin Wolf @ 2020-05-12  8:57 UTC (permalink / raw)
  To: Philippe Mathieu-Daudé
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Alex Bennée, qemu-devel, Markus Armbruster, Stefan Hajnoczi,
	Cleber Rosa, Philippe Mathieu-Daudé

Am 12.05.2020 um 09:06 hat Philippe Mathieu-Daudé geschrieben:
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Reviewed-by: Kevin Wolf <kwolf@redhat.com>



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3 1/2] scripts/qemugdb: Remove shebang header
  2020-05-12  8:55   ` Kevin Wolf
@ 2020-05-12 10:33     ` Philippe Mathieu-Daudé
  0 siblings, 0 replies; 6+ messages in thread
From: Philippe Mathieu-Daudé @ 2020-05-12 10:33 UTC (permalink / raw)
  To: Kevin Wolf
  Cc: Fam Zheng, Eduardo Habkost, qemu-block, qemu-trivial,
	Alex Bennée, qemu-devel, Markus Armbruster, Stefan Hajnoczi,
	Cleber Rosa, Philippe Mathieu-Daudé

On 5/12/20 10:55 AM, Kevin Wolf wrote:
> Am 12.05.2020 um 09:06 hat Philippe Mathieu-Daudé geschrieben:
>> These scripts are loaded as plugin by GDB (and they don't
>> have any __main__ entry point). Remove the shebang header.
>>
>> Acked-by: Alex Bennée <alex.bennee@linaro.org>
>> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
>> ---
>>   scripts/qemugdb/__init__.py  | 3 +--
>>   scripts/qemugdb/aio.py       | 3 +--
>>   scripts/qemugdb/coroutine.py | 3 +--
>>   scripts/qemugdb/mtree.py     | 4 +---
>>   scripts/qemugdb/tcg.py       | 1 -
> 
> There is still a shebang line left in scripts/qemugdb/timers.py.

Oops, thanks for catching this.

> 
> Kevin
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-05-12 10:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-12  7:06 [PATCH v3 0/2] scripts: More Python fixes Philippe Mathieu-Daudé
2020-05-12  7:06 ` [PATCH v3 1/2] scripts/qemugdb: Remove shebang header Philippe Mathieu-Daudé
2020-05-12  8:55   ` Kevin Wolf
2020-05-12 10:33     ` Philippe Mathieu-Daudé
2020-05-12  7:06 ` [PATCH v3 2/2] scripts/qmp: Use Python 3 interpreter Philippe Mathieu-Daudé
2020-05-12  8:57   ` Kevin Wolf

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.