[PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot

Markus Armbruster posted 3 patches 3 years, 9 months ago
Test docker-quick@centos7 failed
Test docker-mingw@fedora failed
Test checkpatch failed
Test FreeBSD failed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20200723142738.1868568-1-armbru@redhat.com
Maintainers: Markus Armbruster <armbru@redhat.com>
scripts/qmp/qom-fuse | 107 +++++++++++++++++++++++--------------------
1 file changed, 57 insertions(+), 50 deletions(-)
[PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot
Posted by Markus Armbruster 3 years, 9 months ago
Markus Armbruster (3):
  scripts/qmp/qom-fuse: Unbreak import of QEMUMonitorProtocol
  scripts/qmp/qom-fuse: Port to current Python module fuse
  scripts/qmp/qom-fuse: Fix getattr(), read() for files in /

 scripts/qmp/qom-fuse | 107 +++++++++++++++++++++++--------------------
 1 file changed, 57 insertions(+), 50 deletions(-)

-- 
2.26.2


Re: [PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot
Posted by Thomas Huth 3 years, 9 months ago
On 23/07/2020 16.27, Markus Armbruster wrote:
> Markus Armbruster (3):
>   scripts/qmp/qom-fuse: Unbreak import of QEMUMonitorProtocol
>   scripts/qmp/qom-fuse: Port to current Python module fuse
>   scripts/qmp/qom-fuse: Fix getattr(), read() for files in /

Could it be added to a CI pipeline, so that it does not bitrot again?

 Thomas


Re: [PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot
Posted by John Snow 3 years, 9 months ago
On 7/23/20 11:21 AM, Thomas Huth wrote:
> On 23/07/2020 16.27, Markus Armbruster wrote:
>> Markus Armbruster (3):
>>    scripts/qmp/qom-fuse: Unbreak import of QEMUMonitorProtocol
>>    scripts/qmp/qom-fuse: Port to current Python module fuse
>>    scripts/qmp/qom-fuse: Fix getattr(), read() for files in /
> 
> Could it be added to a CI pipeline, so that it does not bitrot again?
> 
>   Thomas
> 

Honestly, I'm working on it, but I could use some help getting the 
python directory into shape so I can do it.

I am trying to add pylint/mypy/flake8 tests to python/qemu to prevent 
that code from bitrot, but the review/discussion there didn't go anywhere.

Once there is a solid regime in place for python/qemu/ that is part of 
CI, I can work on moving more scripts and tooling there to start 
including those as part of the CI regime to prevent rot.

--js


Status of scripts/qmp/ (was: [PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot)
Posted by Markus Armbruster 3 years, 9 months ago
Thomas Huth <thuth@redhat.com> writes:

> On 23/07/2020 16.27, Markus Armbruster wrote:
>> Markus Armbruster (3):
>>   scripts/qmp/qom-fuse: Unbreak import of QEMUMonitorProtocol
>>   scripts/qmp/qom-fuse: Port to current Python module fuse
>>   scripts/qmp/qom-fuse: Fix getattr(), read() for files in /
>
> Could it be added to a CI pipeline, so that it does not bitrot again?

Should it be?

Thread hijack!

What's the status of scripts/qmp/?

The directory is covered by MAINTAINERS section QMP, with status
"Supported".  Status is a *lie* for these scripts.  I inherited them
with the rest of QMP.  I have no use for them, except I occasionally use
qom-fuse for QOM spelunking, mostly because our monitor commands are so
unwieldy compared to a filesystem.  I barely looked at them in the 5+
years of my service as QMP maintainer.  Actual status is "Odd fixes".

Does this stuff have any business in /scripts/?

Nothing in scripts/qmp/ should be shipped.

scripts/qmp/qemu-ga-client doesn't even belong there.  Michael, is it of
any use today?

I know scripts/qmp/qmp-shell has a few friends among developers.  I
regard it as a failed attempt at making QMP easier for humans, and have
zero interest in it.

scripts/qmp/qmp looks like an attempt at making QMP easier for shell
scripts.  I'm not aware of actual use, and have zero interest in it.

scripts/qmp/qom-{get,list,set} look like an attempt at making QOM easier
for shell scripts.  I'm not aware of actual use, and have zero interest
in it.  Heck, I can't even figure out how to use qom-get (I just spend
at least 30s trying).

scripts/qmp/qom-tree feels redundant with scripts/qmp/qom-fuse.  I just
ran it for the first time just to come to this judgement.

I believe contrib/ would be a better home for all of them.

I feel like moving the directory there and leaving it *uncovered* in
MAINTAINERS.  If a volunteer steps forward, we can add a suitable
section.

Opinions?


Re: Status of scripts/qmp/ (was: [PATCH 0/3] scripts/qmp/qom-fuse: Scrape off the bitrot)
Posted by Thomas Huth 3 years, 9 months ago
On 24/07/2020 09.33, Markus Armbruster wrote:
> Thomas Huth <thuth@redhat.com> writes:
> 
>> On 23/07/2020 16.27, Markus Armbruster wrote:
>>> Markus Armbruster (3):
>>>   scripts/qmp/qom-fuse: Unbreak import of QEMUMonitorProtocol
>>>   scripts/qmp/qom-fuse: Port to current Python module fuse
>>>   scripts/qmp/qom-fuse: Fix getattr(), read() for files in /
>>
>> Could it be added to a CI pipeline, so that it does not bitrot again?
> 
> Should it be?
> 
> Thread hijack!
> 
> What's the status of scripts/qmp/?
> 
> The directory is covered by MAINTAINERS section QMP, with status
> "Supported".  Status is a *lie* for these scripts.  I inherited them
> with the rest of QMP.  I have no use for them, except I occasionally use
> qom-fuse for QOM spelunking, mostly because our monitor commands are so
> unwieldy compared to a filesystem.  I barely looked at them in the 5+
> years of my service as QMP maintainer.  Actual status is "Odd fixes".
> 
> Does this stuff have any business in /scripts/?
> 
> Nothing in scripts/qmp/ should be shipped.
> 
> scripts/qmp/qemu-ga-client doesn't even belong there.  Michael, is it of
> any use today?
> 
> I know scripts/qmp/qmp-shell has a few friends among developers.  I
> regard it as a failed attempt at making QMP easier for humans, and have
> zero interest in it.
> 
> scripts/qmp/qmp looks like an attempt at making QMP easier for shell
> scripts.  I'm not aware of actual use, and have zero interest in it.
> 
> scripts/qmp/qom-{get,list,set} look like an attempt at making QOM easier
> for shell scripts.  I'm not aware of actual use, and have zero interest
> in it.  Heck, I can't even figure out how to use qom-get (I just spend
> at least 30s trying).

According to the original commit (235fe3bfd46b1104575b540d0bc), it seems
like these were using for manual testing. If in all those years nobody
ever tried to integrate them into our "make check" test suite, I guess
they are just dead code.

> scripts/qmp/qom-tree feels redundant with scripts/qmp/qom-fuse.  I just
> ran it for the first time just to come to this judgement.
> 
> I believe contrib/ would be a better home for all of them.
> 
> I feel like moving the directory there and leaving it *uncovered* in
> MAINTAINERS.  If a volunteer steps forward, we can add a suitable
> section.
> 
> Opinions?

I'd suggest to remove the "test tools" from commit 235fe3bfd46b1104575b5
since apparently nobody ever cared to integrate them into the test suite.

For the other scripts that are still used occasionally, I'd leave them
in their current location. If you don't want to maintain them, remove
them from your section in MAINTAINERS and add a new "QMP scripts"
section where you can mark the scripts/qmp folder as orphan.

 Thomas