Skip to content

Commit dc6e1b6

Browse files
[po] auto sync
1 parent 33be448 commit dc6e1b6

File tree

9 files changed

+143
-108
lines changed

9 files changed

+143
-108
lines changed

library/email.po

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
55
#
66
# Translators:
7-
# Freesand Leo <yuqinju@163.com>, 2019
7+
# Freesand Leo <yuqinju@163.com>, 2021
88
#
99
#, fuzzy
1010
msgid ""
@@ -13,7 +13,7 @@ msgstr ""
1313
"Report-Msgid-Bugs-To: \n"
1414
"POT-Creation-Date: 2021-01-01 05:02+0000\n"
1515
"PO-Revision-Date: 2017-02-16 23:09+0000\n"
16-
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2019\n"
16+
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2021\n"
1717
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
1818
"MIME-Version: 1.0\n"
1919
"Content-Type: text/plain; charset=UTF-8\n"
@@ -27,7 +27,7 @@ msgstr ":mod:`email` --- 电子邮件与 MIME 处理包"
2727

2828
#: ../../library/email.rst:11
2929
msgid "**Source code:** :source:`Lib/email/__init__.py`"
30-
msgstr "**源码:** :source:`Lib/email/__init__.py`"
30+
msgstr "**源代码:** :source:`Lib/email/__init__.py`"
3131

3232
#: ../../library/email.rst:15
3333
msgid ""

library/mmap.po

Lines changed: 27 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# 1f8188eb55931f9e2a00b94ad4501daa_6f620ef <34b4f5f8c2e4e8d305e849ed969d1b03_787452>, 2019
88
# Zombie110year <zombie110year@gmail.com>, 2019
99
# laazy <laaazy@sjtu.edu.cn>, 2020
10-
# Freesand Leo <yuqinju@163.com>, 2020
10+
# Freesand Leo <yuqinju@163.com>, 2021
1111
#
1212
#, fuzzy
1313
msgid ""
@@ -16,7 +16,7 @@ msgstr ""
1616
"Report-Msgid-Bugs-To: \n"
1717
"POT-Creation-Date: 2021-01-01 05:02+0000\n"
1818
"PO-Revision-Date: 2017-02-16 23:18+0000\n"
19-
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2020\n"
19+
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2021\n"
2020
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
2121
"MIME-Version: 1.0\n"
2222
"Content-Type: text/plain; charset=UTF-8\n"
@@ -163,6 +163,9 @@ msgid ""
163163
"that's shared with all other processes mapping the same areas of the file. "
164164
"The default value is :const:`MAP_SHARED`."
165165
msgstr ""
166+
"*flags* 指明映射的性质。 :const:`MAP_PRIVATE` 会创建私有的写入时拷贝映射,因此对 mmap "
167+
"对象内容的修改将为该进程所私有,而 :const:`MAP_SHARED` 会创建与其他映射同一文件区域的进程所共享的映射。 默认值为 "
168+
":const:`MAP_SHARED`。"
166169

167170
#: ../../library/mmap.rst:86
168171
msgid ""
@@ -171,6 +174,9 @@ msgid ""
171174
"that the pages may be read or written. *prot* defaults to :const:`PROT_READ"
172175
" \\| PROT_WRITE`."
173176
msgstr ""
177+
"如果指明了 *prot*,它将给出所需的内存保护方式;最有用的两个值是 :const:`PROT_READ` 和 "
178+
":const:`PROT_WRITE`,分别指明页面为可读或可写。 *prot* 默认为 :const:`PROT_READ \\| "
179+
"PROT_WRITE`。"
174180

175181
#: ../../library/mmap.rst:91
176182
msgid ""
@@ -179,6 +185,8 @@ msgid ""
179185
"*access*. See the description of *access* above for information on how to "
180186
"use this parameter."
181187
msgstr ""
188+
"可以指定 *access* 作为替代 *flags* 和 *prot* 的可选关键字形参。 同时指定 *flags*, *prot* 和 "
189+
"*access* 将导致错误。 请参阅上文中 *access* 的描述了解有关如何使用此形参的信息。"
182190

183191
#: ../../library/mmap.rst:96
184192
msgid ""
@@ -187,47 +195,50 @@ msgid ""
187195
"defaults to 0. *offset* must be a multiple of :const:`ALLOCATIONGRANULARITY`"
188196
" which is equal to :const:`PAGESIZE` on Unix systems."
189197
msgstr ""
198+
"*offset* 可以被指定为非负整数偏移量。 mmap 引用将相对于从文件开头的偏移。 *offset* 默认为 0。 *offset* 必须是 "
199+
":const:`ALLOCATIONGRANULARITY` 的倍数,它在 Unix 系统上等价于 :const:`PAGESIZE`。"
190200

191201
#: ../../library/mmap.rst:101
192202
msgid ""
193203
"To ensure validity of the created memory mapping the file specified by the "
194204
"descriptor *fileno* is internally automatically synchronized with physical "
195205
"backing store on Mac OS X and OpenVMS."
196206
msgstr ""
207+
"要确保已创建内存映射的有效性,描述符 *fileno* 所指定的文件在 Mac OS X 和 OpenVMS 上会与物理后备存储进行内部自动同步。"
197208

198209
#: ../../library/mmap.rst:105
199210
msgid "This example shows a simple way of using :class:`~mmap.mmap`::"
200-
msgstr ""
211+
msgstr "这个例子演示了使用 :class:`~mmap.mmap` 的简单方式::"
201212

202213
#: ../../library/mmap.rst:130
203214
msgid ""
204215
":class:`~mmap.mmap` can also be used as a context manager in a "
205216
":keyword:`with` statement::"
206-
msgstr ""
217+
msgstr ":class:`~mmap.mmap` 也可以在 :keyword:`with` 语句中被用作上下文管理器::"
207218

208219
#: ../../library/mmap.rst:138
209220
msgid "Context manager support."
210-
msgstr ""
221+
msgstr "上下文管理器支持。"
211222

212223
#: ../../library/mmap.rst:142
213224
msgid ""
214225
"The next example demonstrates how to create an anonymous map and exchange "
215226
"data between the parent and child processes::"
216-
msgstr ""
227+
msgstr "下面的例子演示了如何创建一个匿名映射并在父进程和子进程之间交换数据。::"
217228

218229
#: ../../library/mmap.rst:161
219230
msgid "Memory-mapped file objects support the following methods:"
220-
msgstr ""
231+
msgstr "映射内存的文件对象支持以下方法:"
221232

222233
#: ../../library/mmap.rst:165
223234
msgid ""
224235
"Closes the mmap. Subsequent calls to other methods of the object will result"
225236
" in a ValueError exception being raised. This will not close the open file."
226-
msgstr ""
237+
msgstr "关闭 mmap。 后续调用该对象的其他方法将导致引发 ValueError 异常。 此方法将不会关闭打开的文件。"
227238

228239
#: ../../library/mmap.rst:172
229240
msgid "``True`` if the file is closed."
230-
msgstr ""
241+
msgstr "如果文件已关闭则返回 ``True``。"
231242

232243
#: ../../library/mmap.rst:179
233244
msgid ""
@@ -236,6 +247,8 @@ msgid ""
236247
"arguments *start* and *end* are interpreted as in slice notation. Returns "
237248
"``-1`` on failure."
238249
msgstr ""
250+
"返回子序列 *sub* 在对象内被找到的最小索引号,使得 *sub* 被包含在 [*start*, *end*] 范围中。 可选参数 *start* 和"
251+
" *end* 会被解读为切片表示法。 如果未找到则返回 ``-1``。"
239252

240253
#: ../../library/mmap.rst:184 ../../library/mmap.rst:265
241254
#: ../../library/mmap.rst:297
@@ -251,19 +264,23 @@ msgid ""
251264
"extent of the mapping is flushed. *offset* must be a multiple of the "
252265
":const:`PAGESIZE` or :const:`ALLOCATIONGRANULARITY`."
253266
msgstr ""
267+
"将对文件的内存副本的修改刷新至磁盘。 如果不使用此调用则无法保证在对象被销毁前将修改写回存储。 如果指定了 *offset* 和 "
268+
"*size*,则只将对指定范围内字节的修改刷新至磁盘;在其他情况下,映射的全部范围都会被刷新。 *offset* 必须为 "
269+
":const:`PAGESIZE` 或 :const:`ALLOCATIONGRANULARITY` 的倍数。"
254270

255271
#: ../../library/mmap.rst:197
256272
msgid ""
257273
"``None`` is returned to indicate success. An exception is raised when the "
258274
"call failed."
259-
msgstr ""
275+
msgstr "返回 ``None`` 以表示成功。 当调用失败时将引发异常。"
260276

261277
#: ../../library/mmap.rst:200
262278
msgid ""
263279
"Previously, a nonzero value was returned on success; zero was returned on "
264280
"error under Windows. A zero value was returned on success; an exception was"
265281
" raised on error under Unix."
266282
msgstr ""
283+
"在之前版本中,成功时将返回非零值;在 Windows 下当发生错误时将返回零。 在 Unix 下 成功时将返回零值;当发生错误时将引发异常。"
267284

268285
#: ../../library/mmap.rst:208
269286
msgid ""

library/signal.po

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -823,7 +823,7 @@ msgid ""
823823
"The function is now retried if interrupted by a signal not in *sigset* and "
824824
"the signal handler does not raise an exception (see :pep:`475` for the "
825825
"rationale)."
826-
msgstr "当被某个 不在 *sigset* 中的信号中断时本函数将结束并且信号处理程序不会引发异常 (其理由参见 :pep:`475`)。"
826+
msgstr "当被某个 不在 *sigset* 中的信号中断时本函数将进行重试并且信号处理程序不会引发异常(请参阅 :pep:`475` 了解其理由)。"
827827

828828
#: ../../library/signal.rst:602
829829
msgid ""
@@ -851,6 +851,8 @@ msgid ""
851851
"a signal not in *sigset* and the signal handler does not raise an exception "
852852
"(see :pep:`475` for the rationale)."
853853
msgstr ""
854+
"现在当此函数被某个不在 *sigset* 中的信号中断时将以计算出的 *timeout* 进行重试并且信号处理程序不会引发异常(请参阅 "
855+
":pep:`475` 了解其理由)。"
854856

855857
#: ../../library/signal.rst:622
856858
msgid "Example"
@@ -865,10 +867,13 @@ msgid ""
865867
" alarm before opening the file; if the operation takes too long, the alarm "
866868
"signal will be sent, and the handler raises an exception. ::"
867869
msgstr ""
870+
"这是一个最小示例程序。 它使用 :func:`alarm` "
871+
"函数来限制等待打开一个文件所花费的时间;这在文件为无法开启的串行设备时会很有用处,此情况通常会导致 :func:`os.open` 无限期地挂起。 "
872+
"解决办法是在打开文件之前设置 5 秒钟的 alarm;如果操作耗时过长,将会发送 alarm 信号,并且处理程序会引发一个异常。 ::"
868873

869874
#: ../../library/signal.rst:647
870875
msgid "Note on SIGPIPE"
871-
msgstr ""
876+
msgstr "对于 SIGPIPE 的说明"
872877

873878
#: ../../library/signal.rst:649
874879
msgid ""
@@ -878,6 +883,9 @@ msgid ""
878883
":code:`BrokenPipeError: [Errno 32] Broken pipe`. To handle this case, wrap "
879884
"your entry point to catch this exception as follows::"
880885
msgstr ""
886+
"将你的程序用管道输出到工具例如 :manpage:`head(1)` 将会导致 :const:`SIGPIPE` "
887+
"信号在其标准输出的接收方提前关闭时被发送到你的进程。 这将引发一个异常例如 :code:`BrokenPipeError: [Errno 32] "
888+
"Broken pipe`。 要处理这种情况,请对你的入口点进行包装以捕获此异常,如下所示::"
881889

882890
#: ../../library/signal.rst:676
883891
msgid ""
@@ -886,3 +894,5 @@ msgid ""
886894
"unexpectedly also whenever any socket connection is interrupted while your "
887895
"program is still writing to it."
888896
msgstr ""
897+
"不要将 :const:`SIGPIPE` 的处置方式设为 :const:`SIG_DFL` 以避免 :exc:`BrokenPipeError`。 "
898+
"这样做还会在你的程序所写入的任何套接字连接中断时导致你的程序异常退出。"

library/smtplib.po

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
# 陈也在哦 <wenbinchen150@icloud.com>, 2019
1010
# 汪心禾 <wangxinhe06@gmail.com>, 2019
1111
# Arisaka97 <solitaire2312@gmail.com>, 2021
12+
# Freesand Leo <yuqinju@163.com>, 2021
1213
#
1314
#, fuzzy
1415
msgid ""
@@ -17,7 +18,7 @@ msgstr ""
1718
"Report-Msgid-Bugs-To: \n"
1819
"POT-Creation-Date: 2021-01-01 05:02+0000\n"
1920
"PO-Revision-Date: 2017-02-16 23:26+0000\n"
20-
"Last-Translator: Arisaka97 <solitaire2312@gmail.com>, 2021\n"
21+
"Last-Translator: Freesand Leo <yuqinju@163.com>, 2021\n"
2122
"Language-Team: Chinese (China) (https://www.transifex.com/python-doc/teams/5390/zh_CN/)\n"
2223
"MIME-Version: 1.0\n"
2324
"Content-Type: text/plain; charset=UTF-8\n"
@@ -31,7 +32,7 @@ msgstr ":mod:`smtplib` ---SMTP协议客户端"
3132

3233
#: ../../library/smtplib.rst:9
3334
msgid "**Source code:** :source:`Lib/smtplib.py`"
34-
msgstr ""
35+
msgstr "**源代码:** :source:`Lib/smtplib.py`"
3536

3637
#: ../../library/smtplib.rst:17
3738
msgid ""
@@ -40,6 +41,9 @@ msgid ""
4041
"daemon. For details of SMTP and ESMTP operation, consult :rfc:`821` (Simple"
4142
" Mail Transfer Protocol) and :rfc:`1869` (SMTP Service Extensions)."
4243
msgstr ""
44+
":mod:`smtplib` 模块定义了一个 SMTP 客户端会话对象,该对象可将邮件发送到 Internet 上带有 SMTP 或 ESMTP "
45+
"接收程序的计算机。 关于 SMTP 和 ESMTP 操作的详情请参阅 :rfc:`821` (简单邮件传输协议) 和 :rfc:`1869` (SMTP"
46+
" 服务扩展)。"
4347

4448
#: ../../library/smtplib.rst:25
4549
msgid ""
@@ -76,13 +80,17 @@ msgid ""
7680
":meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included "
7781
"below."
7882
msgstr ""
83+
"正常使用时,只需要初始化或 connect 方法,:meth:`sendmail` 方法,再加上 :meth:`SMTP.quit` "
84+
"方法即可。下文包括了一个示例。"
7985

8086
#: ../../library/smtplib.rst:47
8187
msgid ""
8288
"The :class:`SMTP` class supports the :keyword:`with` statement. When used "
8389
"like this, the SMTP ``QUIT`` command is issued automatically when the "
8490
":keyword:`!with` statement exits. E.g.::"
8591
msgstr ""
92+
":class:`SMTP` 类支持 :keyword:`with` 语句。当这样使用时,:keyword:`!with` 语句一退出就会自动发出 "
93+
"SMTP ``QUIT`` 命令。例如::"
8694

8795
#: ../../library/smtplib.rstNone
8896
msgid ""
@@ -743,6 +751,14 @@ msgid ""
743751
":attr:`~email.policy.EmailPolicy.utf8` attribute set to ``True``, and "
744752
"``SMTPUTF8`` and ``BODY=8BITMIME`` are added to *mail_options*."
745753
msgstr ""
754+
"``send_message`` 使用 :class:`~email.generator.BytesGenerator` 来序列化 *msg*,且将 "
755+
"``\\r\\n`` 作为 *linesep*,并调用 :meth:`sendmail` 来传输序列化后的结果。无论 *from_addr* 和 "
756+
"*to_addrs* 的值为何,``send_message`` 都不会传输 *msg* 中可能出现的 :mailheader:`Bcc` 或 "
757+
":mailheader:`Resent-Bcc` 头部。如果 *from_addr* 和 *to_addrs* 中的某个地址包含非 ASCII "
758+
"字符,且服务器没有声明支持 ``SMTPUTF8``,则引发 :exc:`SMTPNotSupported` 错误。如果服务器支持,则 "
759+
"``Message`` 将按新克隆的 :mod:`~email.policy` 进行序列化,其中的 "
760+
":attr:`~email.policy.EmailPolicy.utf8` 属性被设置为 ``True``,且 ``SMTPUTF8`` 和 "
761+
"``BODY=8BITMIME`` 被添加到 *mail_options* 中。"
746762

747763
#: ../../library/smtplib.rst:545
748764
msgid "Support for internationalized addresses (``SMTPUTF8``)."

tutorial/appetite.po

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,9 @@ msgid ""
7777
" problem domain than Awk or even Perl, yet many things are at least as easy "
7878
"in Python as in those languages."
7979
msgstr ""
80-
"Python 虽然简单易用,但它可是一种真正的编程语言,提供了大量的数据结构,也支持开发大型程序,远超shell 脚本或批处理文件;Python "
80+
"Python 虽然简单易用,但它可是真正的编程语言,提供了大量的数据结构,也支持开发大型程序,远超 shell 脚本或批处理文件;Python "
8181
"提供的错误检查比 C 还多;作为一种“非常高级的语言”,它内置了灵活的数组与字典等高级数据类型。正因为配备了更通用的数据类型,Python 比 "
82-
"Awk,甚至 Perl 能处理更多问题,而且,很多时候,Python 和这些语言一样简单。"
82+
"Awk,甚至 Perl 能解决更多问题,而且,很多时候,Python 和这些语言一样简单。"
8383

8484
#: ../../tutorial/appetite.rst:37
8585
msgid ""
@@ -90,8 +90,8 @@ msgid ""
9090
"file I/O, system calls, sockets, and even interfaces to graphical user "
9191
"interface toolkits like Tk."
9292
msgstr ""
93-
"Python 支持把程序分割为模块,可以在其他 Python 程序中复用。它还内置了大量的标准模块,作为开发程序的基础 —— 您还可以把这些模块当作学习"
94-
" Python 编程的实例。这些模块提供了 I/O、系统调用、套接字,甚至 Tk 图形用户界面工作箱。"
93+
"Python 支持把程序分割为模块,以便在其他 Python 程序中复用。它还内置了大量标准模块,作为开发程序的基础 —— 您还可以把这些模块当作学习 "
94+
"Python 编程的实例。这些模块包括 I/O、系统调用、套接字,甚至还保罗 Tk 图形用户界面工作套件。"
9595

9696
#: ../../tutorial/appetite.rst:44
9797
msgid ""
@@ -156,7 +156,7 @@ msgid ""
156156
" more detail. Since the best way to learn a language is to use it, the "
157157
"tutorial invites you to play with the Python interpreter as you read."
158158
msgstr ""
159-
"现在,您已经对 Python 跃跃欲试,想深入了解一些细节了吧。鉴于,学习语言的最佳方式是上手实践,建议您边阅读本教程,边在 Python "
159+
"现在,您已经对 Python 跃跃欲试,想深入了解一些细节了吧。要知道,学习语言的最佳方式是上手实践,建议您边阅读本教程,边在 Python "
160160
"解释器中玩耍。"
161161

162162
#: ../../tutorial/appetite.rst:78
@@ -174,4 +174,4 @@ msgid ""
174174
"advanced concepts like exceptions and user-defined classes."
175175
msgstr ""
176176
"本教程的其他部分将利用各种示例,介绍 Python "
177-
"语言、系统的功能,开始是一些简单的表达式、语句和数据类型,然后是函数、模块,最后,带您了解一些高级概念,如,异常、用户定义的类等功能。"
177+
"语言、系统的功能,开始只是简单的表达式、语句和数据类型,然后是函数、模块,最后,介绍一些高级概念,如,异常、用户定义的类等功能。"

tutorial/datastructures.po

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,7 @@ msgstr "以下是一些简单的示例:"
427427
msgid ""
428428
"Similarly to :ref:`list comprehensions <tut-listcomps>`, set comprehensions "
429429
"are also supported::"
430-
msgstr "类似于 :ref:`列表推导式 <tut-listcomps>`,集合也支持推导式形式 ::"
430+
msgstr " :ref:`列表推导式 <tut-listcomps>` 类似,集合也支持推导式:"
431431

432432
#: ../../tutorial/datastructures.rst:494
433433
msgid "Dictionaries"
@@ -644,11 +644,9 @@ msgid ""
644644
"order individual characters. Some examples of comparisons between sequences "
645645
"of the same type::"
646646
msgstr ""
647-
"序列对象通常与相同序列类型的其他对象比较。 这种比较使用 *字典式* "
648-
"顺序:首先,比较开头的两个对应元素,如果两者不相等,则比较结果就由此确定;如果两者相等,则比较之后的两个元素,以此类推,直到有一个序列被耗尽。 "
649-
"如果要比较的两个元素是相同类型的序列,则会递归地执行字典式顺序比较。 如果两个序列中所有的对应元素都相等,则两个序列相等。 "
650-
"如果一个序列是另一个的初始子序列,则较短的序列就被视为较小(较少)。 对于字符串来说,字典式顺序是使用 Unicode "
651-
"码位序号对单个字符排序。下面列出了一些相同类型序列进行比较的例子:"
647+
"序列对象可以与相同序列类型的其他对象比较。这种比较使用 *字典式* "
648+
"顺序:首先,比较前两个对应元素,如果不相等,则可确定比较结果;如果相等,则比较之后的两个元素,以此类推,直到其中一个序列结束。如果要比较的两个元素本身是相同类型的序列,则递归地执行字典式顺序比较。如果两个序列中所有的对应元素都相等,则两个序列相等。如果一个序列是另一个的初始子序列,则较短的序列可被视为较小(较少)的序列。"
649+
" 对于字符串来说,字典式顺序使用 Unicode 码位序号排序单个字符。下面列出了一些比较相同类型序列的例子:"
652650

653651
#: ../../tutorial/datastructures.rst:724
654652
msgid ""

0 commit comments

Comments
 (0)