Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 60f3109

Browse files
[po] auto sync
1 parent 6f59e5c commit 60f3109

8 files changed

Lines changed: 6515 additions & 6469 deletions

File tree

library/argparse.po

Lines changed: 138 additions & 134 deletions
Large diffs are not rendered by default.

library/contextlib.po

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
# ww song <[email protected]>, 2018
88
# Meng Du <[email protected]>, 2019
99
# nick <[email protected]>, 2019
10-
# Freesand Leo <yuqinju@163.com>, 2019
11-
# cdarlint <cdarling@126.com>, 2019
10+
# Heyi Tang <tangheyi.09@gmail.com>, 2020
11+
# Freesand Leo <yuqinju@163.com>, 2020
1212
#
1313
#, fuzzy
1414
msgid ""
@@ -17,7 +17,7 @@ msgstr ""
1717
"Report-Msgid-Bugs-To: \n"
1818
"POT-Creation-Date: 2020-05-31 09:25+0000\n"
1919
"PO-Revision-Date: 2017-02-16 23:04+0000\n"
20-
"Last-Translator: cdarlint <cdarling@126.com>, 2019\n"
20+
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2020\n"
2121
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
2222
"MIME-Version: 1.0\n"
2323
"Content-Type: text/plain; charset=UTF-8\n"
@@ -28,7 +28,7 @@ msgstr ""
2828
#: ../../library/contextlib.rst:2
2929
msgid ""
3030
":mod:`!contextlib` --- Utilities for :keyword:`!with`\\ -statement contexts"
31-
msgstr ""
31+
msgstr ":mod:`!contextlib` --- 为 :keyword:`!with`\\ 语句上下文提供的工具"
3232

3333
#: ../../library/contextlib.rst:7
3434
msgid "**Source code:** :source:`Lib/contextlib.py`"
@@ -40,7 +40,7 @@ msgid ""
4040
":keyword:`with` statement. For more information see also "
4141
":ref:`typecontextmanager` and :ref:`context-managers`."
4242
msgstr ""
43-
"此模块为涉及 :keyword:`with` 语句的常见任务提供了实用的程序。更多信息请参见 :ref:`typecontextmanager` 和 "
43+
"此模块为涉及 :keyword:`with` 语句的常见任务提供了实用的工具。更多信息请参见 :ref:`typecontextmanager` 和 "
4444
":ref:`context-managers`。"
4545

4646
#: ../../library/contextlib.rst:17
@@ -60,6 +60,10 @@ msgid ""
6060
"default returns ``None``. See also the definition of "
6161
":ref:`typecontextmanager`."
6262
msgstr ""
63+
"一个为实现了 :meth:`object.__enter__` 与 :meth:`object.__exit__` 的类提供的 "
64+
":term:`abstract base class`。为 :meth:`object.__enter__` 提供的一个默认实现是返回 ``self``"
65+
" 而 :meth:`object.__exit__` 是一个默认返回 ``None`` 的抽象方法。 参见 "
66+
":ref:`typecontextmanager` 的定义。"
6367

6468
#: ../../library/contextlib.rst:34
6569
msgid ""
@@ -70,13 +74,19 @@ msgid ""
7074
"default returns ``None``. See also the definition of :ref:`async-context-"
7175
"managers`."
7276
msgstr ""
77+
"一个为实现了 :meth:`object.__aenter__` 与 :meth:`object.__aexit__` 的类提供的 "
78+
":term:`abstract base class`。 为 :meth:`object.__aenter__` 提供的一个默认实现是返回 "
79+
"``self`` 而 :meth:`object.__aexit__` 是一个默认返回 ``None`` 的抽象方法。 参见 :ref:`async-"
80+
"context-managers` 的定义。"
7381

7482
#: ../../library/contextlib.rst:46
7583
msgid ""
7684
"This function is a :term:`decorator` that can be used to define a factory "
7785
"function for :keyword:`with` statement context managers, without needing to "
7886
"create a class or separate :meth:`__enter__` and :meth:`__exit__` methods."
7987
msgstr ""
88+
"这个函数是一个 :term:`decorator` ,它可以定义一个支持 :keyword:`with` 语句上下文管理器的工厂函数, "
89+
"而不需要创建一个类或区 :meth:`__enter__` 与 :meth:`__exit__` 方法。"
8090

8191
#: ../../library/contextlib.rst:50
8292
msgid ""
@@ -85,12 +95,14 @@ msgid ""
8595
"and doesn't implement a ``close()`` method for use with "
8696
"``contextlib.closing``"
8797
msgstr ""
98+
"尽管许多对象原生支持使用 with 语句,但有些需要被管理的资源并不是上下文管理器,并且没有实现 ``close()`` 方法而不能使用 "
99+
"``contextlib.closing`` 。"
88100

89101
#: ../../library/contextlib.rst:54
90102
msgid ""
91103
"An abstract example would be the following to ensure correct resource "
92104
"management::"
93-
msgstr ""
105+
msgstr "下面是一个抽象的示例,展示如何确保正确的资源管理::"
94106

95107
#: ../../library/contextlib.rst:73
96108
msgid ""
@@ -99,7 +111,7 @@ msgid ""
99111
"the targets in the :keyword:`with` statement's :keyword:`!as` clause, if "
100112
"any."
101113
msgstr ""
102-
"被装饰的函数在被调用时,必须返回一个 :term:`generator`-iterator。这个迭代器必须只 yield 一个值出来,这个值会被用在 "
114+
"被装饰的函数在被调用时,必须返回一个 :term:`generator` 迭代器。 这个迭代器必须只 yield 一个值出来,这个值会被用在 "
103115
":keyword:`with` 语句中,绑定到 :keyword:`!as` 后面的变量,如果给定了的话。"
104116

105117
#: ../../library/contextlib.rst:77
@@ -117,6 +129,11 @@ msgid ""
117129
"handled, and execution will resume with the statement immediately following "
118130
"the :keyword:`!with` statement."
119131
msgstr ""
132+
"当生成器发生 yield 时,嵌套在 :keyword:`with` 语句中的语句体会被执行。 语句体执行完毕离开之后,该生成器将被恢复执行。 "
133+
"如果在该语句体中发生了未处理的异常,则该异常会在生成器发生 yield 时重新被引发。 因此,你可以使用 :keyword:`try`...\\ "
134+
":keyword:`except`...\\ :keyword:`finally` 语句来捕获该异常(如果有的话),或确保进行了一些清理。 "
135+
"如果仅出于记录日志或执行某些操作(而非完全抑制异常)的目的捕获了异常,生成器必须重新引发该异常。 否则生成器的上下文管理器将向 "
136+
":keyword:`!with` 语句指示该异常已经被处理,程序将立即在 :keyword:`!with` 语句之后恢复并继续执行。"
120137

121138
#: ../../library/contextlib.rst:89
122139
msgid ""
@@ -128,10 +145,13 @@ msgid ""
128145
"that context managers support multiple invocations in order to be used as "
129146
"decorators)."
130147
msgstr ""
148+
":func:`contextmanager` 使用 :class:`ContextDecorator` 因此它创建的上下文管理器不仅可以用在 "
149+
":keyword:`with` 语句中,还可以用作一个装饰器。当它用作一个装饰器时,每一次函数调用时都会隐式创建一个新的生成器实例(这使得 "
150+
":func:`contextmanager` 创建的上下文管理器满足了支持多次调用以用作装饰器的需求,而非“一次性”的上下文管理器)。"
131151

132152
#: ../../library/contextlib.rst:96
133153
msgid "Use of :class:`ContextDecorator`."
134-
msgstr ""
154+
msgstr ":class:`ContextDecorator` 的使用。"
135155

136156
#: ../../library/contextlib.rst:102
137157
msgid ""

library/ipaddress.po

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
55
#
66
# Translators:
7-
# Freesand Leo <[email protected]>, 2019
87
# Sean Chao <[email protected]>, 2020
8+
# Freesand Leo <[email protected]>, 2020
99
#
1010
#, fuzzy
1111
msgid ""
@@ -14,7 +14,7 @@ msgstr ""
1414
"Report-Msgid-Bugs-To: \n"
1515
"POT-Creation-Date: 2020-05-31 09:25+0000\n"
1616
"PO-Revision-Date: 2017-02-16 23:15+0000\n"
17-
"Last-Translator: Sean Chao <seanchao0804@gmail.com>, 2020\n"
17+
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2020\n"
1818
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
1919
"MIME-Version: 1.0\n"
2020
"Content-Type: text/plain; charset=UTF-8\n"
@@ -70,6 +70,9 @@ msgid ""
7070
" A :exc:`ValueError` is raised if *address* does not represent a valid IPv4 "
7171
"or IPv6 address."
7272
msgstr ""
73+
"返回一个 :class:`IPv4Address` 或 :class:`IPv6Address` 对象,取决于作为参数传递的 IP "
74+
"地址。可以提供IPv4或IPv6地址,小于 2**32 的整数默认被认为是 IPv4。如果 *address* 不是有效的 IPv4 或 IPv6 "
75+
"地址,则会抛出 :exc:`ValueError`。"
7376

7477
#: ../../library/ipaddress.rst:56
7578
msgid ""
@@ -81,6 +84,10 @@ msgid ""
8184
":exc:`ValueError` is raised if *address* does not represent a valid IPv4 or "
8285
"IPv6 address, or if the network has host bits set."
8386
msgstr ""
87+
"返回一个 :class:`IPv4Network` 或 :class:`IPv6Network` 对象,具体取决于作为参数传入的 IP 地址。 "
88+
"*address* 是表示 IP 网址的字符串或整数。 可以提供 IPv4 或 IPv6 网址;小于 2**32 的整数默认被视为 IPv4。 "
89+
"*strict* 会被传给 :class:`IPv4Network` 或 :class:`IPv6Network` 构造器。 如果 *address* "
90+
"不表示有效的 IPv4 或 IPv6 网址,或者网络设置了 host 比特位,则会引发 :exc:`ValueError`。"
8491

8592
#: ../../library/ipaddress.rst:70
8693
msgid ""
@@ -91,6 +98,9 @@ msgid ""
9198
":exc:`ValueError` is raised if *address* does not represent a valid IPv4 or "
9299
"IPv6 address."
93100
msgstr ""
101+
"返回一个 :class:`IPv4Interface` 或 :class:`IPv6Interface` 对象,取决于作为参数传递的 IP 地址。 "
102+
"*address* 是代表 IP 地址的字符串或整数。 可以提供 IPv4 或 IPv6 地址,小于 2**32 的整数默认认为是 IPv4。 如果 "
103+
"*address* 不是有效的IPv4 或 IPv6 地址,则会抛出一个 :exc:`ValueError`。"
94104

95105
#: ../../library/ipaddress.rst:77
96106
msgid ""
@@ -100,14 +110,15 @@ msgid ""
100110
"format was intended. More detailed error reporting can be obtained by "
101111
"calling the appropriate version specific class constructors directly."
102112
msgstr ""
113+
"这些方便的函数的一个缺点是需要同时处理IPv4和IPv6格式,这意味着提供的错误信息并不精准,因为函数不知道是打算采用IPv4还是IPv6格式。更详细的错误报告可以通过直接调用相应版本的类构造函数来获得。"
103114

104115
#: ../../library/ipaddress.rst:86
105116
msgid "IP Addresses"
106-
msgstr ""
117+
msgstr "IP 地址"
107118

108119
#: ../../library/ipaddress.rst:89
109120
msgid "Address objects"
110-
msgstr ""
121+
msgstr "地址对象"
111122

112123
#: ../../library/ipaddress.rst:91
113124
msgid ""
@@ -118,16 +129,20 @@ msgid ""
118129
"Address objects are :term:`hashable`, so they can be used as keys in "
119130
"dictionaries."
120131
msgstr ""
132+
":class:`IPv4Address` 和 :class:`IPv6Address` 对象有很多共同的属性。一些只对IPv6 地址有意义的属性也在 "
133+
":class:`IPv4Address` 对象实现,以便更容易编写正确处理两种 IP 版本的代码。地址对象是可哈希的 "
134+
":term:`hashable`,所以它们可以作为字典中的键来使用。"
121135

122136
#: ../../library/ipaddress.rst:99
123137
msgid ""
124138
"Construct an IPv4 address. An :exc:`AddressValueError` is raised if "
125139
"*address* is not a valid IPv4 address."
126140
msgstr ""
141+
"构造一个 IPv4 地址。 如果 *address* 不是一个有效的 IPv4 地址,会抛出 :exc:`AddressValueError` 。"
127142

128143
#: ../../library/ipaddress.rst:102
129144
msgid "The following constitutes a valid IPv4 address:"
130-
msgstr ""
145+
msgstr "以下是有效的 IPv4 地址:"
131146

132147
#: ../../library/ipaddress.rst:104
133148
msgid ""
@@ -137,16 +152,18 @@ msgid ""
137152
"tolerated only for values less than 8 (as there is no ambiguity between the "
138153
"decimal and octal interpretations of such strings)."
139154
msgstr ""
155+
"以十进制小数点表示的字符串,由四个十进制整数组成,范围为0--255,用点隔开(例如 ``192.168.0.1`` "
156+
")。每个整数代表地址中的八位(一个字节)。只有对于小于8的值,才允许使用前导零(因为对这种字符串的十进制和八进制解释之间没有任何歧义)。"
140157

141158
#: ../../library/ipaddress.rst:109
142159
msgid "An integer that fits into 32 bits."
143-
msgstr ""
160+
msgstr "一个32位可容纳的整数。"
144161

145162
#: ../../library/ipaddress.rst:110
146163
msgid ""
147164
"An integer packed into a :class:`bytes` object of length 4 (most significant"
148165
" octet first)."
149-
msgstr ""
166+
msgstr "一个长度为 4 的封装在 :class:`bytes` 对象中的整数(高位优先)。"
150167

151168
#: ../../library/ipaddress.rst:122
152169
msgid "The appropriate version number: ``4`` for IPv4, ``6`` for IPv6."

library/ssl.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# cdarlint <[email protected]>, 2019
1313
# Zombie110year <[email protected]>, 2019
1414
# ppcfish <[email protected]>, 2019
15-
# KaMingChung <[email protected]>, 2020
15+
# KM.C <[email protected]>, 2020
1616
#
1717
#, fuzzy
1818
msgid ""
@@ -21,7 +21,7 @@ msgstr ""
2121
"Report-Msgid-Bugs-To: \n"
2222
"POT-Creation-Date: 2020-05-31 09:25+0000\n"
2323
"PO-Revision-Date: 2017-02-16 23:27+0000\n"
24-
"Last-Translator: KaMingChung <[email protected]>, 2020\n"
24+
"Last-Translator: KM.C <[email protected]>, 2020\n"
2525
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
2626
"MIME-Version: 1.0\n"
2727
"Content-Type: text/plain; charset=UTF-8\n"

library/sys.po

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1415,6 +1415,8 @@ msgid ""
14151415
"The :term:`named tuple` :data:`sys.version_info` may be used for a more "
14161416
"human-friendly encoding of the same information."
14171417
msgstr ""
1418+
"之所以称它为 ``hexversion``,是因为只有将它传入内置函数 :func:`hex` 后,其结果才看起来有意义。也可以使用 "
1419+
":term:`具名元组 <named tuple>` :data:`sys.version_info`,它对相同信息有着更人性化的编码。"
14181420

14191421
#: ../../library/sys.rst:862
14201422
msgid "More details of ``hexversion`` can be found at :ref:`apiabiversion`."

library/zoneinfo.po

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,12 +353,14 @@ msgid ""
353353
"zone database (e.g. ``America/New_York``, ``Europe/Paris`` or "
354354
"``Asia/Tokyo``)."
355355
msgstr ""
356+
"这是一个只读的 :term:`attribute`,它返回传给构造器的 ``key`` 的值,该值应为一个 IANA 时区数据库的查找键 (例如 "
357+
"``America/New_York``, ``Europe/Paris`` 或 ``Asia/Tokyo``)。"
356358

357359
#: ../../library/zoneinfo.rst:253
358360
msgid ""
359361
"For zones constructed from file without specifying a ``key`` parameter, this"
360362
" will be set to ``None``."
361-
msgstr ""
363+
msgstr "对于不指定 ``key`` 形参而是基于文件构造时区,该属性将设为 ``None``。"
362364

363365
#: ../../library/zoneinfo.rst:258
364366
msgid ""

tutorial/classes.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
# zkonge <[email protected]>, 2019
1212
# Shengjing Zhu <[email protected]>, 2019
1313
# Freesand Leo <[email protected]>, 2020
14-
# KaMingChung <[email protected]>, 2020
14+
# KM.C <[email protected]>, 2020
1515
#
1616
#, fuzzy
1717
msgid ""
@@ -20,7 +20,7 @@ msgstr ""
2020
"Report-Msgid-Bugs-To: \n"
2121
"POT-Creation-Date: 2020-07-14 03:37+0000\n"
2222
"PO-Revision-Date: 2017-02-16 23:39+0000\n"
23-
"Last-Translator: KaMingChung <[email protected]>, 2020\n"
23+
"Last-Translator: KM.C <[email protected]>, 2020\n"
2424
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
2525
"MIME-Version: 1.0\n"
2626
"Content-Type: text/plain; charset=UTF-8\n"

0 commit comments

Comments
 (0)