Skip to content

[Docs] Fix missing blank line after .. py:function:: directive in RST files#7809

Merged
Echo-Nie merged 1 commit intoPaddlePaddle:developfrom
StatefulDust:fix/rst-blank-line-after-pyfunction-def13817b6917a07
Mar 1, 2026
Merged

[Docs] Fix missing blank line after .. py:function:: directive in RST files#7809
Echo-Nie merged 1 commit intoPaddlePaddle:developfrom
StatefulDust:fix/rst-blank-line-after-pyfunction-def13817b6917a07

Conversation

@ooooo-create
Copy link
Copy Markdown
Collaborator

Summary

Fixed missing blank lines after .. py:function:: directives in three inplace API documentation files.

Problem

In ReStructuredText (RST) syntax, a blank line is required between a directive header and its description content for proper parsing. The following files were missing this blank line:

  • docs/api/paddle/gammainc__cn.rst
  • docs/api/paddle/gammaincc__cn.rst
  • docs/api/paddle/gcd__cn.rst

Before (non-compliant):

.. py:function:: paddle.gammainc_(x, y, name=None)
Inplace 版本的 :ref:`cn_api_paddle_gammainc` API,对输入 `x` 采用 Inplace 策略。

After (compliant):

.. py:function:: paddle.gammainc_(x, y, name=None)

Inplace 版本的 :ref:`cn_api_paddle_gammainc` API,对输入 `x` 采用 Inplace 策略。

Relevant Standard

From the documentation guidelines (.github/copilot-instructions.md):

应当注意中文 API 文档使用语法为 ReStructuredText(.rst),而非 Markdown(.md)。请遵守 ReStructuredText 的语法规范。

This matches the formatting already used in similar inplace API docs such as gammaln__cn.rst which correctly has a blank line after the directive.

Generated by API Docs Checker


🔄 Synced from https://github.com/StatefulDust/paddle-docs-agent/pull/18

Add missing blank lines after '.. py:function::' directives in three
inplace API documentation files. In ReStructuredText, a blank line is
required between the directive header and its description content for
proper parsing.

Fixed files:
- docs/api/paddle/gammainc__cn.rst
- docs/api/paddle/gammaincc__cn.rst
- docs/api/paddle/gcd__cn.rst

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings March 1, 2026 00:55
@paddle-bot
Copy link
Copy Markdown

paddle-bot bot commented Mar 1, 2026

感谢你贡献飞桨文档,文档预览构建中,Docs-New 跑完后即可预览,预览链接:http://preview-pr-7809.paddle-docs-preview.paddlepaddle.org.cn/documentation/docs/zh/api/index_cn.html
预览工具的更多说明,请参考:飞桨文档预览工具

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 1, 2026

📚 本次 PR 文档预览链接(点击展开)
ℹ️ 预览提醒
请等待 Docs-NEW 流水线运行完成后再点击预览链接,否则可能会看到旧版本内容或遇到链接无法访问的情况。

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

该 PR 针对 PaddlePaddle 中文 inplace API 的 .rst 文档做语法格式修正,补齐 .. py:function:: 指令行与后续说明段落之间缺失的空行,以符合 ReStructuredText 的指令书写规范并避免潜在解析问题。

Changes:

  • gammainc_ / gammaincc_ / gcd_ 三个 inplace API 文档在 .. py:function:: 后补充空行
  • 使三处文档格式与同类 inplace API 文档保持一致

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
docs/api/paddle/gcd__cn.rst .. py:function:: paddle.gcd_ 后补充空行,修复 RST 指令段落分隔
docs/api/paddle/gammaincc__cn.rst .. py:function:: paddle.gammaincc_ 后补充空行,修复 RST 指令段落分隔
docs/api/paddle/gammainc__cn.rst .. py:function:: paddle.gammainc_ 后补充空行,修复 RST 指令段落分隔

@Echo-Nie Echo-Nie merged commit 1c93224 into PaddlePaddle:develop Mar 1, 2026
9 checks passed
@ooooo-create ooooo-create added the HappyOpenSource 快乐开源活动issue与PR label Mar 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

HappyOpenSource 快乐开源活动issue与PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants