AnswerDotAI / AnswerDotAI/nbdev
keyword only '*' does not work with documentation
- Dominant language
- Jupyter Notebook
- Stars
- 5.3k
- Forks
- 513
- Avg merge
- 2d 30m
- Merged PRs (30d)
- 8
Description
# Example
Hello! Using keyword only argument such as:
```python
#| export
def super_func(
keyword_or_non_keyword_arg, # this is a keyword or non-keyword arg
*,
keyword_only_arg # this is a keyword only arg
) -> str: # return string
"super func"
...
```
makes the documentation not working:
```python
show_doc(super_func)
```
```
super_func
super_func (keyword_or_non_keyword_arg, keyword_only_arg)
super func
| | Type | Details | | – | ——– | ———– | | keyword_or_non_keyword_arg | | this is a keyword or non-keyword arg | | keyword_only_arg | | | | Returns | str | return string |
```
the documentation for keyword_only_arg is absent
# Configuration
Python 3.7.16
nbdev 2.3.12
Contributor guide
Research direction
Start by reproducing the issue with the shown Python 3.7.16 example and show_doc(super_func) in nbdev 2.3.12. Trace how the keyword-only parameter is represented in the generated documentation; done means keyword_only_arg appears with its documentation and the existing parameter details remain correct.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- jupyter, python
- Domain
- documentation
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100