Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docstring description multiline parsing #476

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
Prev Previous commit
Next Next commit
Updated to per-arg state
  • Loading branch information
thebadcoder96 committed Jan 14, 2024
commit 2458562690a1bff030cfc1cd191c40b79855d11c
2 changes: 0 additions & 2 deletions fire/docstrings.py
Original file line number Diff line number Diff line change
Expand Up @@ -448,12 +448,10 @@ def _merge_if_long_arg(state):
state: The state of the docstring parser.
"""
actual_max_line_len = roundup(state.max_line_length)
print(state.max_line_length, actual_max_line_len)
arg = state.current_arg
arg_length = len(arg.name)
percent_105 = 1.05 * actual_max_line_len
long_arg_name = roundup(arg_length) >= 0.4 * actual_max_line_len
print(arg_length, long_arg_name)
if long_arg_name:
if arg.line2_first_word_length:
line1_plus_first_word = arg.line1_length + arg.line2_first_word_length
Expand Down