File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -636,17 +636,17 @@ msgid ""
636636":meth:`str.format` or :class:`string.Template`. Here's an example console "
637637"session to show the possibilities:"
638638msgstr ""
639- "日志(从 3.2 开始)为这两种格式化方式提供了更多支持 。:class:`Formatter` 类可以添加一个额外的可选关键字参数 "
640- "``style``。它的默认值是 ``'%'``,其他的值 ``'{'`` 和 ``'$'`` "
641- "也支持,对应了其他两种格式化样式。其保持了向后兼容(如您所愿),但通过显示指定样式参数,你可以指定格式化字符串的方式是使用 "
642- ":meth:`str.format` 或 :class:`string.Template`。 这里是一个控制台会话的示例,展示了这些方式: "
639+ "从 Python 3.2 开始,日志模块为后加入的两种格式化方式提供了更多支持 。:class:`Formatter` 得以增强,可以接受名为 "
640+ "``style`` 的可选关键字参数。其默认值为 ``'%'`` ,其他还可以是 ``'{'`` 和 ``'{TX-PL- "
641+ "LABEL}#x27;``,对应于另外两种格式化的样式。如您所料,默认保持向下兼容,而通过显式指定样式参数,能够设置用于 "
642+ ":meth:`str.format` 或 :class:`string.Template` 的格式串。下面是个控制台会话示例,演示一下功能: "
643643
644644#: ../../howto/logging-cookbook.rst:1089
645645msgid ""
646646"Note that the formatting of logging messages for final output to logs is "
647647"completely independent of how an individual logging message is constructed. "
648648"That can still use %-formatting, as shown here::"
649- msgstr "请注意最终输出到日志的消息格式完全独立于单条日志消息的构造方式。 它仍然可以使用 %-formatting ,如下所示:: "
649+ msgstr "请注意,最终输出到日志的信息格式与某一条信息的构造方式完全独立。某条信息仍然可以采用 %-f 格式 ,如下所示: "
650650
651651#: ../../howto/logging-cookbook.rst:1097
652652msgid ""
You can’t perform that action at this time.
0 commit comments