[Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements

Markus Armbruster posted 16 patches 4 years, 7 months ago
Test docker-clang@ubuntu passed
Test FreeBSD passed
Test checkpatch failed
Test docker-quick@centos7 passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190910063724.28470-1-armbru@redhat.com
Maintainers: Michael Roth <mdroth@linux.vnet.ibm.com>, Markus Armbruster <armbru@redhat.com>
There is a newer version of this series
docs/devel/qapi-code-gen.txt                  | 1068 ++++++++++-------
tests/test-qmp-cmds.c                         |    4 +
scripts/git.orderfile                         |    4 +-
scripts/qapi/commands.py                      |    4 +-
scripts/qapi/common.py                        |  144 +--
scripts/qapi/events.py                        |   10 +-
tests/Makefile.include                        |    7 +-
tests/qapi-schema/alternate-empty.err         |    2 +-
tests/qapi-schema/alternate-empty.json        |    4 +-
tests/qapi-schema/args-boxed-empty.err        |    1 -
tests/qapi-schema/args-boxed-empty.json       |    3 -
tests/qapi-schema/args-invalid.err            |    2 +-
tests/qapi-schema/doc-missing.err             |    2 +-
tests/qapi-schema/doc-no-symbol.err           |    2 +-
tests/qapi-schema/enum-bad-name.err           |    2 +-
tests/qapi-schema/enum-bad-name.json          |    3 +-
tests/qapi-schema/enum-clash-member.err       |    2 +-
.../qapi-schema/enum-dict-member-unknown.err  |    2 +-
tests/qapi-schema/enum-member-case.err        |    2 +-
tests/qapi-schema/escape-outside-string.err   |    1 -
tests/qapi-schema/escape-outside-string.json  |    3 -
tests/qapi-schema/escape-too-big.err          |    1 -
tests/qapi-schema/escape-too-big.exit         |    1 -
tests/qapi-schema/escape-too-big.json         |    3 -
tests/qapi-schema/escape-too-big.out          |    0
tests/qapi-schema/escape-too-short.err        |    1 -
tests/qapi-schema/escape-too-short.exit       |    1 -
tests/qapi-schema/escape-too-short.json       |    3 -
tests/qapi-schema/escape-too-short.out        |    0
tests/qapi-schema/flat-union-empty.err        |    2 +-
tests/qapi-schema/flat-union-empty.json       |    2 +-
tests/qapi-schema/ident-with-escape.err       |    1 +
tests/qapi-schema/ident-with-escape.exit      |    2 +-
tests/qapi-schema/ident-with-escape.json      |    2 +-
tests/qapi-schema/ident-with-escape.out       |   16 -
tests/qapi-schema/pragma-non-dict.err         |    2 +-
tests/qapi-schema/qapi-schema-test.json       |   13 +-
tests/qapi-schema/qapi-schema-test.out        |   21 +-
tests/qapi-schema/string-code-point-127.err   |    1 +
...-empty.exit => string-code-point-127.exit} |    0
tests/qapi-schema/string-code-point-127.json  |    2 +
...ed-empty.out => string-code-point-127.out} |    0
tests/qapi-schema/string-code-point-31.err    |    1 +
...-string.exit => string-code-point-31.exit} |    0
tests/qapi-schema/string-code-point-31.json   |    2 +
...de-string.out => string-code-point-31.out} |    0
tests/qapi-schema/struct-data-invalid.err     |    2 +-
tests/qapi-schema/unicode-str.err             |    1 -
tests/qapi-schema/unicode-str.exit            |    1 -
tests/qapi-schema/unicode-str.json            |    2 -
tests/qapi-schema/unicode-str.out             |    0
tests/qapi-schema/union-empty.err             |    2 +-
tests/qapi-schema/union-empty.json            |    2 +-
tests/qapi-schema/unknown-escape.json         |    2 +-
54 files changed, 737 insertions(+), 624 deletions(-)
delete mode 100644 tests/qapi-schema/args-boxed-empty.err
delete mode 100644 tests/qapi-schema/args-boxed-empty.json
delete mode 100644 tests/qapi-schema/escape-outside-string.err
delete mode 100644 tests/qapi-schema/escape-outside-string.json
delete mode 100644 tests/qapi-schema/escape-too-big.err
delete mode 100644 tests/qapi-schema/escape-too-big.exit
delete mode 100644 tests/qapi-schema/escape-too-big.json
delete mode 100644 tests/qapi-schema/escape-too-big.out
delete mode 100644 tests/qapi-schema/escape-too-short.err
delete mode 100644 tests/qapi-schema/escape-too-short.exit
delete mode 100644 tests/qapi-schema/escape-too-short.json
delete mode 100644 tests/qapi-schema/escape-too-short.out
create mode 100644 tests/qapi-schema/string-code-point-127.err
rename tests/qapi-schema/{args-boxed-empty.exit => string-code-point-127.exit} (100%)
create mode 100644 tests/qapi-schema/string-code-point-127.json
rename tests/qapi-schema/{args-boxed-empty.out => string-code-point-127.out} (100%)
create mode 100644 tests/qapi-schema/string-code-point-31.err
rename tests/qapi-schema/{escape-outside-string.exit => string-code-point-31.exit} (100%)
create mode 100644 tests/qapi-schema/string-code-point-31.json
rename tests/qapi-schema/{escape-outside-string.out => string-code-point-31.out} (100%)
delete mode 100644 tests/qapi-schema/unicode-str.err
delete mode 100644 tests/qapi-schema/unicode-str.exit
delete mode 100644 tests/qapi-schema/unicode-str.json
delete mode 100644 tests/qapi-schema/unicode-str.out
[Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements
Posted by Markus Armbruster 4 years, 7 months ago
v2:
* PATCH v1 05: Dropped
* PATCH 01,05,07-11,16: New
* PATCH 03:
  - Commit message typo fixed
  - Assertions tightened
* PATCH 04:
  - Document member name 'u' is reserved
  - Drop an accidental change to section "Enumeration types"
  - Typo fixed
* PATCH 06:
  - Outlaw anything but printable ASCII, not just control characters
* PATCH 15:
  - Adopt more convenient terminology: directive, definition
  - Explanation of grammar notation missed grouping
  - Drop a more text redundant with the grammar
  - Drop more text redundant with section "Naming rules and reserved
    names"
  - Turn "boxed needs data: STRING" into syntax
  - Improve section "Documentation comments" some more
  - Minor phrasing tweaks

Markus Armbruster (16):
  scripts/git.orderfile: Match QAPI schema more precisely
  qapi: Drop check_type()'s redundant parameter @allow_optional
  qapi: Drop support for boxed alternate arguments
  docs/devel/qapi-code-gen: Minor specification fixes
  tests/qapi-schema: Demonstrate bad reporting of funny characters
  qapi: Restrict strings to printable ASCII
  qapi: Drop support for escape sequences other than \\
  qapi: Permit 'boxed' with empty type
  qapi: Permit alternates with just one branch
  qapi: Permit omitting all flat union branches
  qapi: Adjust frontend errors to say enum value, not member
  docs/devel/qapi-code-gen: Reorder sections for readability
  docs/devel/qapi-code-gen: Rewrite compatibility considerations
  docs/devel/qapi-code-gen: Rewrite introduction to schema
  docs/devel/qapi-code-gen: Improve QAPI schema language doc
  qapi: Tweak code to match docs/devel/qapi-code-gen.txt

 docs/devel/qapi-code-gen.txt                  | 1068 ++++++++++-------
 tests/test-qmp-cmds.c                         |    4 +
 scripts/git.orderfile                         |    4 +-
 scripts/qapi/commands.py                      |    4 +-
 scripts/qapi/common.py                        |  144 +--
 scripts/qapi/events.py                        |   10 +-
 tests/Makefile.include                        |    7 +-
 tests/qapi-schema/alternate-empty.err         |    2 +-
 tests/qapi-schema/alternate-empty.json        |    4 +-
 tests/qapi-schema/args-boxed-empty.err        |    1 -
 tests/qapi-schema/args-boxed-empty.json       |    3 -
 tests/qapi-schema/args-invalid.err            |    2 +-
 tests/qapi-schema/doc-missing.err             |    2 +-
 tests/qapi-schema/doc-no-symbol.err           |    2 +-
 tests/qapi-schema/enum-bad-name.err           |    2 +-
 tests/qapi-schema/enum-bad-name.json          |    3 +-
 tests/qapi-schema/enum-clash-member.err       |    2 +-
 .../qapi-schema/enum-dict-member-unknown.err  |    2 +-
 tests/qapi-schema/enum-member-case.err        |    2 +-
 tests/qapi-schema/escape-outside-string.err   |    1 -
 tests/qapi-schema/escape-outside-string.json  |    3 -
 tests/qapi-schema/escape-too-big.err          |    1 -
 tests/qapi-schema/escape-too-big.exit         |    1 -
 tests/qapi-schema/escape-too-big.json         |    3 -
 tests/qapi-schema/escape-too-big.out          |    0
 tests/qapi-schema/escape-too-short.err        |    1 -
 tests/qapi-schema/escape-too-short.exit       |    1 -
 tests/qapi-schema/escape-too-short.json       |    3 -
 tests/qapi-schema/escape-too-short.out        |    0
 tests/qapi-schema/flat-union-empty.err        |    2 +-
 tests/qapi-schema/flat-union-empty.json       |    2 +-
 tests/qapi-schema/ident-with-escape.err       |    1 +
 tests/qapi-schema/ident-with-escape.exit      |    2 +-
 tests/qapi-schema/ident-with-escape.json      |    2 +-
 tests/qapi-schema/ident-with-escape.out       |   16 -
 tests/qapi-schema/pragma-non-dict.err         |    2 +-
 tests/qapi-schema/qapi-schema-test.json       |   13 +-
 tests/qapi-schema/qapi-schema-test.out        |   21 +-
 tests/qapi-schema/string-code-point-127.err   |    1 +
 ...-empty.exit => string-code-point-127.exit} |    0
 tests/qapi-schema/string-code-point-127.json  |    2 +
 ...ed-empty.out => string-code-point-127.out} |    0
 tests/qapi-schema/string-code-point-31.err    |    1 +
 ...-string.exit => string-code-point-31.exit} |    0
 tests/qapi-schema/string-code-point-31.json   |    2 +
 ...de-string.out => string-code-point-31.out} |    0
 tests/qapi-schema/struct-data-invalid.err     |    2 +-
 tests/qapi-schema/unicode-str.err             |    1 -
 tests/qapi-schema/unicode-str.exit            |    1 -
 tests/qapi-schema/unicode-str.json            |    2 -
 tests/qapi-schema/unicode-str.out             |    0
 tests/qapi-schema/union-empty.err             |    2 +-
 tests/qapi-schema/union-empty.json            |    2 +-
 tests/qapi-schema/unknown-escape.json         |    2 +-
 54 files changed, 737 insertions(+), 624 deletions(-)
 delete mode 100644 tests/qapi-schema/args-boxed-empty.err
 delete mode 100644 tests/qapi-schema/args-boxed-empty.json
 delete mode 100644 tests/qapi-schema/escape-outside-string.err
 delete mode 100644 tests/qapi-schema/escape-outside-string.json
 delete mode 100644 tests/qapi-schema/escape-too-big.err
 delete mode 100644 tests/qapi-schema/escape-too-big.exit
 delete mode 100644 tests/qapi-schema/escape-too-big.json
 delete mode 100644 tests/qapi-schema/escape-too-big.out
 delete mode 100644 tests/qapi-schema/escape-too-short.err
 delete mode 100644 tests/qapi-schema/escape-too-short.exit
 delete mode 100644 tests/qapi-schema/escape-too-short.json
 delete mode 100644 tests/qapi-schema/escape-too-short.out
 create mode 100644 tests/qapi-schema/string-code-point-127.err
 rename tests/qapi-schema/{args-boxed-empty.exit => string-code-point-127.exit} (100%)
 create mode 100644 tests/qapi-schema/string-code-point-127.json
 rename tests/qapi-schema/{args-boxed-empty.out => string-code-point-127.out} (100%)
 create mode 100644 tests/qapi-schema/string-code-point-31.err
 rename tests/qapi-schema/{escape-outside-string.exit => string-code-point-31.exit} (100%)
 create mode 100644 tests/qapi-schema/string-code-point-31.json
 rename tests/qapi-schema/{escape-outside-string.out => string-code-point-31.out} (100%)
 delete mode 100644 tests/qapi-schema/unicode-str.err
 delete mode 100644 tests/qapi-schema/unicode-str.exit
 delete mode 100644 tests/qapi-schema/unicode-str.json
 delete mode 100644 tests/qapi-schema/unicode-str.out

-- 
2.21.0


Re: [Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements
Posted by no-reply@patchew.org 4 years, 7 months ago
Patchew URL: https://patchew.org/QEMU/20190910063724.28470-1-armbru@redhat.com/



Hi,

This series seems to have some coding style problems. See output below for
more information:

Subject: [Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements
Message-id: 20190910063724.28470-1-armbru@redhat.com
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
 - [tag update]      patchew/20190910063724.28470-1-armbru@redhat.com -> patchew/20190910063724.28470-1-armbru@redhat.com
Switched to a new branch 'test'
446351c qapi: Tweak code to match docs/devel/qapi-code-gen.txt
16bdba8 docs/devel/qapi-code-gen: Improve QAPI schema language doc
cb81f1d docs/devel/qapi-code-gen: Rewrite introduction to schema
1536401 docs/devel/qapi-code-gen: Rewrite compatibility considerations
4d82648 docs/devel/qapi-code-gen: Reorder sections for readability
9ac7ecd qapi: Adjust frontend errors to say enum value, not member
e106b86 qapi: Permit omitting all flat union branches
81dc6c5 qapi: Permit alternates with just one branch
bf905ed qapi: Permit 'boxed' with empty type
312a323 qapi: Drop support for escape sequences other than \\
2a77c2f qapi: Restrict strings to printable ASCII
f6aaeaa tests/qapi-schema: Demonstrate bad reporting of funny characters
bd4e9cc docs/devel/qapi-code-gen: Minor specification fixes
88cff11 qapi: Drop support for boxed alternate arguments
b9e08ee qapi: Drop check_type()'s redundant parameter @allow_optional
6860186 scripts/git.orderfile: Match QAPI schema more precisely

=== OUTPUT BEGIN ===
1/16 Checking commit 6860186b207b (scripts/git.orderfile: Match QAPI schema more precisely)
2/16 Checking commit b9e08eee03e3 (qapi: Drop check_type()'s redundant parameter @allow_optional)
3/16 Checking commit 88cff11d85d8 (qapi: Drop support for boxed alternate arguments)
4/16 Checking commit bd4e9cc1f433 (docs/devel/qapi-code-gen: Minor specification fixes)
5/16 Checking commit f6aaeaa74c63 (tests/qapi-schema: Demonstrate bad reporting of funny characters)
6/16 Checking commit 2a77c2f2e0ec (qapi: Restrict strings to printable ASCII)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#98: 
new file mode 100644

ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
#115: FILE: tests/qapi-schema/string-code-point-127.json:2:
+{ 'command': '⌦' }
               ^

ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
#141: FILE: tests/qapi-schema/string-code-point-31.json:2:
+{ 'command': '␟' }
               ^

total: 2 errors, 1 warnings, 67 lines checked

Patch 6/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

7/16 Checking commit 312a323451bc (qapi: Drop support for escape sequences other than \\)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#69: 
deleted file mode 100644

total: 0 errors, 1 warnings, 49 lines checked

Patch 7/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
8/16 Checking commit bf905eda09c9 (qapi: Permit 'boxed' with empty type)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#129: 
deleted file mode 100644

total: 0 errors, 1 warnings, 129 lines checked

Patch 8/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
9/16 Checking commit 81dc6c516180 (qapi: Permit alternates with just one branch)
10/16 Checking commit e106b8638164 (qapi: Permit omitting all flat union branches)
11/16 Checking commit 9ac7ecd2cc24 (qapi: Adjust frontend errors to say enum value, not member)
12/16 Checking commit 4d8264892e00 (docs/devel/qapi-code-gen: Reorder sections for readability)
13/16 Checking commit 1536401f46a4 (docs/devel/qapi-code-gen: Rewrite compatibility considerations)
14/16 Checking commit cb81f1def7f2 (docs/devel/qapi-code-gen: Rewrite introduction to schema)
15/16 Checking commit 16bdba8b8274 (docs/devel/qapi-code-gen: Improve QAPI schema language doc)
16/16 Checking commit 446351ca29ad (qapi: Tweak code to match docs/devel/qapi-code-gen.txt)
=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20190910063724.28470-1-armbru@redhat.com/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Re: [Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements
Posted by no-reply@patchew.org 4 years, 7 months ago
Patchew URL: https://patchew.org/QEMU/20190910063724.28470-1-armbru@redhat.com/



Hi,

This series seems to have some coding style problems. See output below for
more information:

Subject: [Qemu-devel] [PATCH v2 00/16] qapi: Schema language cleanups & doc improvements
Message-id: 20190910063724.28470-1-armbru@redhat.com
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Switched to a new branch 'test'
a1653d5 qapi: Tweak code to match docs/devel/qapi-code-gen.txt
099aa0e docs/devel/qapi-code-gen: Improve QAPI schema language doc
831ceca docs/devel/qapi-code-gen: Rewrite introduction to schema
b2d2173 docs/devel/qapi-code-gen: Rewrite compatibility considerations
e3fee5f docs/devel/qapi-code-gen: Reorder sections for readability
5a3026a qapi: Adjust frontend errors to say enum value, not member
da3e5ce qapi: Permit omitting all flat union branches
29a78dc qapi: Permit alternates with just one branch
1690f90 qapi: Permit 'boxed' with empty type
4db101b qapi: Drop support for escape sequences other than \\
226a021 qapi: Restrict strings to printable ASCII
b7bf351 tests/qapi-schema: Demonstrate bad reporting of funny characters
e4bbc54 docs/devel/qapi-code-gen: Minor specification fixes
afba881 qapi: Drop support for boxed alternate arguments
1988fff qapi: Drop check_type()'s redundant parameter @allow_optional
2f4a210 scripts/git.orderfile: Match QAPI schema more precisely

=== OUTPUT BEGIN ===
1/16 Checking commit 2f4a2105c5e3 (scripts/git.orderfile: Match QAPI schema more precisely)
2/16 Checking commit 1988fff693a1 (qapi: Drop check_type()'s redundant parameter @allow_optional)
3/16 Checking commit afba881b77d4 (qapi: Drop support for boxed alternate arguments)
4/16 Checking commit e4bbc5479810 (docs/devel/qapi-code-gen: Minor specification fixes)
5/16 Checking commit b7bf3512c9eb (tests/qapi-schema: Demonstrate bad reporting of funny characters)
6/16 Checking commit 226a021e435b (qapi: Restrict strings to printable ASCII)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#98: 
new file mode 100644

ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
#115: FILE: tests/qapi-schema/string-code-point-127.json:2:
+{ 'command': '⌦' }
               ^

ERROR: Invalid UTF-8, patch and commit message should be encoded in UTF-8
#141: FILE: tests/qapi-schema/string-code-point-31.json:2:
+{ 'command': '␟' }
               ^

total: 2 errors, 1 warnings, 67 lines checked

Patch 6/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

7/16 Checking commit 4db101b60dce (qapi: Drop support for escape sequences other than \\)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#69: 
deleted file mode 100644

total: 0 errors, 1 warnings, 49 lines checked

Patch 7/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
8/16 Checking commit 1690f908e9c9 (qapi: Permit 'boxed' with empty type)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#129: 
deleted file mode 100644

total: 0 errors, 1 warnings, 129 lines checked

Patch 8/16 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
9/16 Checking commit 29a78dc3574f (qapi: Permit alternates with just one branch)
10/16 Checking commit da3e5ce8445d (qapi: Permit omitting all flat union branches)
11/16 Checking commit 5a3026a89b6c (qapi: Adjust frontend errors to say enum value, not member)
12/16 Checking commit e3fee5f2aebc (docs/devel/qapi-code-gen: Reorder sections for readability)
13/16 Checking commit b2d2173f6812 (docs/devel/qapi-code-gen: Rewrite compatibility considerations)
14/16 Checking commit 831cecae22b1 (docs/devel/qapi-code-gen: Rewrite introduction to schema)
15/16 Checking commit 099aa0e26496 (docs/devel/qapi-code-gen: Improve QAPI schema language doc)
16/16 Checking commit a1653d5a7388 (qapi: Tweak code to match docs/devel/qapi-code-gen.txt)
=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20190910063724.28470-1-armbru@redhat.com/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com