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

Skip to content

Commit 30a7633

Browse files
[po] auto sync
1 parent 554d3b8 commit 30a7633

8 files changed

Lines changed: 92 additions & 46 deletions

File tree

.stat.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"translation": "89.29%", "updated_at": "2023-08-05T12:58:09Z"}
1+
{"translation": "89.31%", "updated_at": "2023-08-05T15:57:03Z"}

c-api/module.po

Lines changed: 78 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ msgid ""
1818
msgstr ""
1919
"Project-Id-Version: Python 3.12\n"
2020
"Report-Msgid-Bugs-To: \n"
21-
"POT-Creation-Date: 2023-07-29 02:08+0000\n"
21+
"POT-Creation-Date: 2023-08-04 14:13+0000\n"
2222
"PO-Revision-Date: 2021-06-28 00:49+0000\n"
2323
"Last-Translator: Freesand Leo <[email protected]>, 2023\n"
2424
"Language-Team: Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
@@ -494,15 +494,56 @@ msgid ""
494494
"order they appear in the *m_slots* array."
495495
msgstr "如果指定了多个 ``Py_mod_exec`` 槽位,将按照它们在*m_slots*数组中出现的顺序进行处理。"
496496

497-
#: ../../c-api/module.rst:379
497+
#: ../../c-api/module.rst:381
498+
msgid "Specifies one of the following values:"
499+
msgstr "指定以下的值之一:"
500+
501+
#: ../../c-api/module.rst:385
502+
msgid "The module does not support being imported in subinterpreters."
503+
msgstr "该模块不支持在子解释器中导入。"
504+
505+
#: ../../c-api/module.rst:389
506+
msgid ""
507+
"The module supports being imported in subinterpreters, but only when they "
508+
"share the main interpreter's GIL. (See :ref:`isolating-extensions-howto`.)"
509+
msgstr ""
510+
"该模块支持在子解释器中导入,但是它们必须要共享主解释器的 GIL。 (参见 :ref:`isolating-extensions-howto`。)"
511+
512+
#: ../../c-api/module.rst:395
513+
msgid ""
514+
"The module supports being imported in subinterpreters, even when they have "
515+
"their own GIL. (See :ref:`isolating-extensions-howto`.)"
516+
msgstr "该模块支持在子解释器中导入,即使它们有自己的 GIL。 (参见 :ref:`isolating-extensions-howto`。)"
517+
518+
#: ../../c-api/module.rst:399
519+
msgid ""
520+
"This slot determines whether or not importing this module in a "
521+
"subinterpreter will fail."
522+
msgstr "此槽位决定在子解释器中导入此模块是否会失败。"
523+
524+
#: ../../c-api/module.rst:402
525+
msgid ""
526+
"Multiple ``Py_mod_multiple_interpreters`` slots may not be specified in one "
527+
"module definition."
528+
msgstr "在一个模块定义中不能指定多个 ``Py_mod_multiple_interpreters`` 槽位。"
529+
530+
#: ../../c-api/module.rst:405
531+
msgid ""
532+
"If ``Py_mod_multiple_interpreters`` is not specified, the import machinery "
533+
"defaults to ``Py_MOD_MULTIPLE_INTERPRETERS_NOT_SUPPORTED``."
534+
msgstr ""
535+
"如果未指定 ``Py_mod_multiple_interpreters``,则导入机制默认为 "
536+
"``Py_MOD_MULTIPLE_INTERPRETERS_NOT_SUPPORTED``。"
537+
538+
#: ../../c-api/module.rst:410
498539
msgid "See :PEP:`489` for more details on multi-phase initialization."
499540
msgstr "有关多阶段初始化的更多细节,请参阅PEP:`489`"
500541

501-
#: ../../c-api/module.rst:382
542+
#: ../../c-api/module.rst:413
502543
msgid "Low-level module creation functions"
503544
msgstr "底层模块创建函数"
504545

505-
#: ../../c-api/module.rst:384
546+
#: ../../c-api/module.rst:415
506547
msgid ""
507548
"The following functions are called under the hood when using multi-phase "
508549
"initialization. They can be used directly, for example when creating module "
@@ -512,7 +553,7 @@ msgstr ""
512553
"当使用多阶段初始化时,将会调用以下函数。例如,在动态创建模块对象的时候,可以直接使用它们。注意,必须调用 "
513554
"``PyModule_FromDefAndSpec`` 和 ``PyModule_ExecDef`` 来完整地初始化一个模块。"
514555

515-
#: ../../c-api/module.rst:391
556+
#: ../../c-api/module.rst:422
516557
msgid ""
517558
"Create a new module object, given the definition in *def* and the ModuleSpec"
518559
" *spec*. This behaves like :c:func:`PyModule_FromDefAndSpec2` with "
@@ -522,7 +563,7 @@ msgstr ""
522563
":c:func:`PyModule_FromDefAndSpec2` 将 *module_api_version* 设为 "
523564
":c:macro:`PYTHON_API_VERSION`。"
524565

525-
#: ../../c-api/module.rst:399
566+
#: ../../c-api/module.rst:430
526567
msgid ""
527568
"Create a new module object, given the definition in *def* and the ModuleSpec"
528569
" *spec*, assuming the API version *module_api_version*. If that version does"
@@ -532,17 +573,17 @@ msgstr ""
532573
"创建一个新的模块对象,在参数 *def* 和 *spec* 中给出定义,设置API版本为参数 "
533574
"*module_api_version*。如果该版本与正在运行的解释器版本不匹配,则会触发 :exc:`RuntimeWarning`。"
534575

535-
#: ../../c-api/module.rst:406
576+
#: ../../c-api/module.rst:437
536577
msgid ""
537578
"Most uses of this function should be using :c:func:`PyModule_FromDefAndSpec`"
538579
" instead; only use this if you are sure you need it."
539580
msgstr "大多数时候应该使用 :c:func:`PyModule_FromDefAndSpec` 代替使用此函数,除非你确定需要使用它。"
540581

541-
#: ../../c-api/module.rst:413
582+
#: ../../c-api/module.rst:444
542583
msgid "Process any execution slots (:c:data:`Py_mod_exec`) given in *def*."
543584
msgstr "执行参数*def*中给出的任意执行槽(:c:data:`Py_mod_exec`)。"
544585

545-
#: ../../c-api/module.rst:419
586+
#: ../../c-api/module.rst:450
546587
msgid ""
547588
"Set the docstring for *module* to *docstring*. This function is called "
548589
"automatically when creating a module from ``PyModuleDef``, using either "
@@ -551,7 +592,7 @@ msgstr ""
551592
"将*module*的文档字符串设置为*docstring*。当使用 ``PyModule_Create`` 或 "
552593
"``PyModule_FromDefAndSpec`` 从 ``PyModuleDef`` 创建模块时,会自动调用此函数。"
553594

554-
#: ../../c-api/module.rst:428
595+
#: ../../c-api/module.rst:459
555596
msgid ""
556597
"Add the functions from the ``NULL`` terminated *functions* array to "
557598
"*module*. Refer to the :c:type:`PyMethodDef` documentation for details on "
@@ -568,60 +609,60 @@ msgstr ""
568609
"``PyModule_Create`` 或 ``PyModule_FromDefAndSpec`` 从 ``PyModuleDef`` "
569610
"创建模块时,会自动调用此函数。"
570611

571-
#: ../../c-api/module.rst:440
612+
#: ../../c-api/module.rst:471
572613
msgid "Support functions"
573614
msgstr "支持函数"
574615

575-
#: ../../c-api/module.rst:442
616+
#: ../../c-api/module.rst:473
576617
msgid ""
577618
"The module initialization function (if using single phase initialization) or"
578619
" a function called from a module execution slot (if using multi-phase "
579620
"initialization), can use the following functions to help initialize the "
580621
"module state:"
581622
msgstr "模块初始化函数(单阶段初始化)或通过模块的执行槽位调用的函数(多阶段初始化),可以使用以下函数,来帮助初始化模块的状态:"
582623

583-
#: ../../c-api/module.rst:449
624+
#: ../../c-api/module.rst:480
584625
msgid ""
585626
"Add an object to *module* as *name*. This is a convenience function which "
586627
"can be used from the module's initialization function."
587628
msgstr "将一个名称为*name*的对象添加到*module*模块中。这是一个方便的函数,可以在模块的初始化函数中使用。"
588629

589-
#: ../../c-api/module.rst:452
630+
#: ../../c-api/module.rst:483
590631
msgid ""
591632
"On success, return ``0``. On error, raise an exception and return ``-1``."
592633
msgstr "如果成功,返回 ``0``。如果发生错误,引发异常并返回 ``-1``。"
593634

594-
#: ../../c-api/module.rst:454
635+
#: ../../c-api/module.rst:485
595636
msgid ""
596637
"Return ``NULL`` if *value* is ``NULL``. It must be called with an exception "
597638
"raised in this case."
598639
msgstr "如果*value*为 ``NULL``,返回 ``NULL``。在调用它时发生这种情况,必须抛出异常。"
599640

600-
#: ../../c-api/module.rst:457 ../../c-api/module.rst:506
641+
#: ../../c-api/module.rst:488 ../../c-api/module.rst:537
601642
msgid "Example usage::"
602643
msgstr "用法示例:"
603644

604-
#: ../../c-api/module.rst:471 ../../c-api/module.rst:524
645+
#: ../../c-api/module.rst:502 ../../c-api/module.rst:555
605646
msgid ""
606647
"The example can also be written without checking explicitly if *obj* is "
607648
"``NULL``::"
608649
msgstr "这个例子也可以写成不显式地检查 *obj* 是否为 ``NULL``::"
609650

610-
#: ../../c-api/module.rst:483 ../../c-api/module.rst:540
651+
#: ../../c-api/module.rst:514 ../../c-api/module.rst:571
611652
msgid ""
612653
"Note that ``Py_XDECREF()`` should be used instead of ``Py_DECREF()`` in this"
613654
" case, since *obj* can be ``NULL``."
614655
msgstr ""
615656
"注意在此情况下应当使用 ``Py_XDECREF()`` 而不是 ``Py_DECREF()``,因为 *obj* 可能为 ``NULL``。"
616657

617-
#: ../../c-api/module.rst:491
658+
#: ../../c-api/module.rst:522
618659
msgid ""
619660
"Similar to :c:func:`PyModule_AddObjectRef`, but steals a reference to "
620661
"*value* on success (if it returns ``0``)."
621662
msgstr ""
622663
"类似于 :c:func:`PyModule_AddObjectRef`,但会在成功时偷取一个对 *value* 的引用(如果它返回 ``0`` 值)。"
623664

624-
#: ../../c-api/module.rst:494
665+
#: ../../c-api/module.rst:525
625666
msgid ""
626667
"The new :c:func:`PyModule_AddObjectRef` function is recommended, since it is"
627668
" easy to introduce reference leaks by misusing the "
@@ -630,19 +671,19 @@ msgstr ""
630671
"推荐使用新的 :c:func:`PyModule_AddObjectRef` 函数,因为误用 :c:func:`PyModule_AddObject` "
631672
"函数很容易导致引用泄漏。"
632673

633-
#: ../../c-api/module.rst:500
674+
#: ../../c-api/module.rst:531
634675
msgid ""
635676
"Unlike other functions that steal references, ``PyModule_AddObject()`` only "
636677
"decrements the reference count of *value* **on success**."
637678
msgstr "和其它窃取引用的函数不同,``PyModule_AddObject()`` 只在**成功**时减少*value*的引用计数。"
638679

639-
#: ../../c-api/module.rst:503
680+
#: ../../c-api/module.rst:534
640681
msgid ""
641682
"This means that its return value must be checked, and calling code must "
642683
":c:func:`Py_DECREF` *value* manually on error."
643684
msgstr "这意味着必须检查它的返回值,调用方必须在发生错误时手动为*value*调用 :c:func:`Py_DECREF`。"
644685

645-
#: ../../c-api/module.rst:546
686+
#: ../../c-api/module.rst:577
646687
msgid ""
647688
"Add an integer constant to *module* as *name*. This convenience function "
648689
"can be used from the module's initialization function. Return ``-1`` on "
@@ -651,7 +692,7 @@ msgstr ""
651692
"将一个名称为*name*的整型常量添加到*module*模块中。这个方便的函数可以在模块的初始化函数中使用。如果发生错误,返回 ``-1``,成功返回 "
652693
"``0``。"
653694

654-
#: ../../c-api/module.rst:553
695+
#: ../../c-api/module.rst:584
655696
msgid ""
656697
"Add a string constant to *module* as *name*. This convenience function can "
657698
"be used from the module's initialization function. The string *value* must "
@@ -660,7 +701,7 @@ msgstr ""
660701
"将一个名称为*name*的字符串常量添加到*module*模块中。这个方便的函数可以在模块的初始化函数中使用。字符串*value*必须以 "
661702
"``NULL`` 结尾。如果发生错误,返回 ``-1`` ,成功返回 ``0`` 。"
662703

663-
#: ../../c-api/module.rst:560
704+
#: ../../c-api/module.rst:591
664705
msgid ""
665706
"Add an int constant to *module*. The name and the value are taken from "
666707
"*macro*. For example ``PyModule_AddIntMacro(module, AF_INET)`` adds the int "
@@ -671,11 +712,11 @@ msgstr ""
671712
"AF_INET)`` 将值为*AF_INET*的整型常量*AF_INET*添加到*module*模块中。如果发生错误,返回 ``-1`` ,成功返回 "
672713
"``0`` 。"
673714

674-
#: ../../c-api/module.rst:568
715+
#: ../../c-api/module.rst:599
675716
msgid "Add a string constant to *module*."
676717
msgstr "将一个字符串常量添加到*module*模块中。"
677718

678-
#: ../../c-api/module.rst:572
719+
#: ../../c-api/module.rst:603
679720
msgid ""
680721
"Add a type object to *module*. The type object is finalized by calling "
681722
"internally :c:func:`PyType_Ready`. The name of the type object is taken from"
@@ -685,25 +726,25 @@ msgstr ""
685726
"将一个类型对象添加到 *module* 模块中。类型对象通过在函数内部调用 :c:func:`PyType_Ready` 完成初始化。类型对象的名称取自"
686727
" :c:member:`~PyTypeObject.tp_name` 最后一个点号之后的部分。如果发生错误,返回 ``-1``,成功返回 ``0``。"
687728

688-
#: ../../c-api/module.rst:582
729+
#: ../../c-api/module.rst:613
689730
msgid "Module lookup"
690731
msgstr "查找模块"
691732

692-
#: ../../c-api/module.rst:584
733+
#: ../../c-api/module.rst:615
693734
msgid ""
694735
"Single-phase initialization creates singleton modules that can be looked up "
695736
"in the context of the current interpreter. This allows the module object to "
696737
"be retrieved later with only a reference to the module definition."
697738
msgstr "单阶段初始化创建可以在当前解释器上下文中被查找的单例模块。这使得仅通过模块定义的引用,就可以检索模块对象。"
698739

699-
#: ../../c-api/module.rst:588
740+
#: ../../c-api/module.rst:619
700741
msgid ""
701742
"These functions will not work on modules created using multi-phase "
702743
"initialization, since multiple such modules can be created from a single "
703744
"definition."
704745
msgstr "这些函数不适用于通过多阶段初始化创建的模块,因为可以从一个模块定义创建多个模块对象。"
705746

706-
#: ../../c-api/module.rst:593
747+
#: ../../c-api/module.rst:624
707748
msgid ""
708749
"Returns the module object that was created from *def* for the current "
709750
"interpreter. This method requires that the module object has been attached "
@@ -714,18 +755,18 @@ msgstr ""
714755
"返回当前解释器中由 *def* 创建的模块对象。此方法要求模块对象此前已通过 :c:func:`PyState_AddModule` "
715756
"函数附加到解释器状态中。如果找不到相应的模块对象,或模块对象还未附加到解释器状态,返回 ``NULL``。"
716757

717-
#: ../../c-api/module.rst:600
758+
#: ../../c-api/module.rst:631
718759
msgid ""
719760
"Attaches the module object passed to the function to the interpreter state. "
720761
"This allows the module object to be accessible via "
721762
":c:func:`PyState_FindModule`."
722763
msgstr "将传给函数的模块对象附加到解释器状态。 这将允许通过 :c:func:`PyState_FindModule` 来访问该模块对象。"
723764

724-
#: ../../c-api/module.rst:603
765+
#: ../../c-api/module.rst:634
725766
msgid "Only effective on modules created using single-phase initialization."
726767
msgstr "仅在使用单阶段初始化创建的模块上有效。"
727768

728-
#: ../../c-api/module.rst:605
769+
#: ../../c-api/module.rst:636
729770
msgid ""
730771
"Python calls ``PyState_AddModule`` automatically after importing a module, "
731772
"so it is unnecessary (but harmless) to call it from module initialization "
@@ -739,15 +780,15 @@ msgstr ""
739780
"显式的调用仅在模块自己的初始化代码后继调用了 ``PyState_FindModule`` 的情况下才是必要的。 "
740781
"此函数主要是为了实现替代导入机制(或是通过直接调用它,或是通过引用它的实现来获取所需的状态更新详情)。"
741782

742-
#: ../../c-api/module.rst:613 ../../c-api/module.rst:624
783+
#: ../../c-api/module.rst:644 ../../c-api/module.rst:655
743784
msgid "The caller must hold the GIL."
744785
msgstr "调用时必须携带GIL。"
745786

746-
#: ../../c-api/module.rst:615
787+
#: ../../c-api/module.rst:646
747788
msgid "Return 0 on success or -1 on failure."
748789
msgstr "成功是返回 0 或者失败时返回 -1。"
749790

750-
#: ../../c-api/module.rst:621
791+
#: ../../c-api/module.rst:652
751792
msgid ""
752793
"Removes the module object created from *def* from the interpreter state. "
753794
"Return 0 on success or -1 on failure."

faq/general.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ msgid ""
1313
msgstr ""
1414
"Project-Id-Version: Python 3.12\n"
1515
"Report-Msgid-Bugs-To: \n"
16-
"POT-Creation-Date: 2023-07-29 02:08+0000\n"
16+
"POT-Creation-Date: 2023-08-04 14:13+0000\n"
1717
"PO-Revision-Date: 2021-06-28 00:52+0000\n"
1818
"Last-Translator: Freesand Leo <[email protected]>, 2023\n"
1919
"Language-Team: Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
@@ -642,7 +642,7 @@ msgstr ""
642642
"高水准的 Python 项目包括 `Mailman 邮件列表管理器 <https://www.list.org>`_ 和 `Zope 应用服务器 "
643643
"<https://www.zope.dev>`_。 多个 Linux 发行版,其中最著名的是 `Red Hat "
644644
"<https://www.redhat.com>`_,都使用 Python 来编写其部分或全部的安装器和系统管理软件。 在内部使用 Python "
645-
"的公司包括了 Google, Yahoo, and Lucasfilm 等等。"
645+
"的公司包括了 Google, Yahoo Lucasfilm 等等。"
646646

647647
#: ../../faq/general.rst:346
648648
msgid "What new developments are expected for Python in the future?"

library/email.message.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -960,7 +960,7 @@ msgstr "移除所有载荷和所有标头。"
960960
msgid ""
961961
"Remove the payload and all of the :mailheader:`!Content-` headers, leaving "
962962
"all other headers intact and in their original order."
963-
msgstr ""
963+
msgstr "移除载荷以及所有 :mailheader:`!Content-` 标头,保持所有其他标头不变并保留其原始顺序。"
964964

965965
#: ../../library/email.message.rst:698
966966
msgid ":class:`EmailMessage` objects have the following instance attributes:"

library/json.po

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,8 @@ msgid ""
234234
":meth:`~JSONEncoder.default` method to serialize additional types), specify "
235235
"it with the *cls* kwarg; otherwise :class:`JSONEncoder` is used."
236236
msgstr ""
237+
"要使用自定义的 :class:`JSONEncoder` 子类(例如重载了 :meth:`~JSONEncoder.default` "
238+
"方法来序列化额外类型),请使用 *cls* 关键字参数来指定它;否则将使用 :class:`JSONEncoder`。"
237239

238240
#: ../../library/json.rst:198 ../../library/json.rst:277
239241
msgid ""

library/stat.po

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#
66
# Translators:
77
# ppcfish <[email protected]>, 2021
8-
# Freesand Leo <[email protected]>, 2022
8+
# Freesand Leo <[email protected]>, 2023
99
#
1010
#, fuzzy
1111
msgid ""
@@ -14,7 +14,7 @@ msgstr ""
1414
"Report-Msgid-Bugs-To: \n"
1515
"POT-Creation-Date: 2023-08-04 14:13+0000\n"
1616
"PO-Revision-Date: 2021-06-28 01:13+0000\n"
17-
"Last-Translator: Freesand Leo <[email protected]>, 2022\n"
17+
"Last-Translator: Freesand Leo <[email protected]>, 2023\n"
1818
"Language-Team: Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
1919
"MIME-Version: 1.0\n"
2020
"Content-Type: text/plain; charset=UTF-8\n"
@@ -37,6 +37,9 @@ msgid ""
3737
"exist). For complete details about the :c:func:`stat`, :c:func:`!fstat` and"
3838
" :c:func:`!lstat` calls, consult the documentation for your system."
3939
msgstr ""
40+
":mod:`stat` 模块定义了一些用于解读 :func:`os.stat`, :func:`os.fstat` 和 :func:`os.lstat`"
41+
" (如果它们存在) 输出结果的常量和函数。 有关 :c:func:`stat`, :c:func:`!fstat` 和 :c:func:`!lstat`"
42+
" 调用的完整细节,请参阅你的系统文档。"
4043

4144
#: ../../library/stat.rst:19
4245
msgid "The stat module is backed by a C implementation."

library/winreg.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ msgstr "常量"
721721
#: ../../library/winreg.rst:539
722722
msgid ""
723723
"The following constants are defined for use in many :mod:`winreg` functions."
724-
msgstr ""
724+
msgstr "以下常量被定义以供多个 :mod:`winreg` 函数使用。"
725725

726726
#: ../../library/winreg.rst:544
727727
msgid "HKEY_* Constants"
@@ -970,7 +970,7 @@ msgstr "本模块中所有接受注册表句柄对象的注册表函数,也能
970970
#: ../../library/winreg.rst:748
971971
msgid ""
972972
"Handle objects provide semantics for :meth:`~object.__bool__` -- thus ::"
973-
msgstr ""
973+
msgstr "句柄对象为 :meth:`~object.__bool__` 提供语义 —— 因此 ::"
974974

975975
#: ../../library/winreg.rst:753
976976
msgid ""

0 commit comments

Comments
 (0)