Skip to content

Fix extra space generated by "generate_json_rpc_docs.py"#3737

Open
dingodoppelt wants to merge 1 commit into
jamulussoftware:mainfrom
dingodoppelt:fix_rpc_docs_tool
Open

Fix extra space generated by "generate_json_rpc_docs.py"#3737
dingodoppelt wants to merge 1 commit into
jamulussoftware:mainfrom
dingodoppelt:fix_rpc_docs_tool

Conversation

@dingodoppelt

@dingodoppelt dingodoppelt commented Jun 14, 2026

Copy link
Copy Markdown
Member

The python tool for generating the RPC documentation adds an extra space character after line breaks starting with /// because it treats the first space character as part of the string, this PR fixes it.

CHANGELOG: Fix extra space generated by "generate_json_rpc_docs.py" in multi line comments

Does this change need documentation? What needs to be documented and how?
No

Status of this Pull Request

Ready to be merged

Checklist

  • I've verified that this Pull Request follows the general code principles
  • I tested my code and it does what I want
  • My code follows the style guide
  • I waited some time after this Pull Request was opened and all GitHub checks completed without errors.
  • I've filled all the content above

current_item.handle_text(line[len("/// @result "):])
elif line.startswith("///"):
current_item.handle_text(line[len("///"):])
current_item.handle_text(line[len("///") + 1:])

@pljones pljones Jun 15, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is + 1 safe? Wouldn't it be safer to trim leading space? Or pattern match ///<whitespace> and take everything after it. Or whatever python can do.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is + 1 safe? Wouldn't it be safer to trim leading space? Or pattern match ///<whitespace> and take everything after it. Or whatever python can do.

Yes, I guess matching the whitespace as well makes more sense here. Maybe @dtinth wants to have a look at this as well, since it is his code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants