Skip to content

Commit fdb7e44

Browse files
authored
Merge pull request #3 from mikelolasagasti/ga-python310
Fix tests for python-3.10 and add 3.10 to CI matrix
2 parents 425745f + a7b186a commit fdb7e44

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
python-version: [3.6, 3.7, 3.8, 3.9]
19+
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
2020
os: [ubuntu-latest]
2121
env:
2222
PYTHON: ${{ matrix.python-version }}

sphinxarg/parser.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,9 @@ def parse_parser(parser, data=None, **kwargs):
154154
continue
155155

156156
# Upper case "Positional Arguments" and "Optional Arguments" titles
157-
if action_group.title == 'optional arguments':
157+
# Since python-3.10 'optional arguments' changed to 'options'
158+
# more info: https://github.com/python/cpython/pull/23858
159+
if action_group.title == 'optional arguments' or action_group.title == 'options':
158160
action_group.title = 'Named Arguments'
159161
if action_group.title == 'positional arguments':
160162
action_group.title = 'Positional Arguments'

0 commit comments

Comments
 (0)