Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5a0b48f

Browse files
[po] auto sync
1 parentf20d6bb commit5a0b48f

File tree

2 files changed

+39
-3
lines changed

2 files changed

+39
-3
lines changed

‎.stat.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"translation":"81.63%","updated_at":"2025-04-28T02:26:35Z"}
1+
{"translation":"81.64%","updated_at":"2025-04-28T03:16:47Z"}

‎whatsnew/3.3.po

Lines changed: 38 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -819,6 +819,8 @@ msgid ""
819819
" multiple subgenerators as easily as a single large function can be split "
820820
"into multiple subfunctions."
821821
msgstr""
822+
"推动这项改变的主要原则是允许即便被设计用来配合 ``send`` 和 ``throw`` "
823+
"方法使用的生成器也能像一个大函数能拆分成多个子函数那样容易地拆分为多个子生成器。"
822824

823825
#:../../whatsnew/3.3.rst:462
824826
msgid":pep:`380` - Syntax for Delegating to a Subgenerator"
@@ -842,7 +844,7 @@ msgid ""
842844
"PEP 409 introduces new syntax that allows the display of the chained "
843845
"exception context to be disabled. This allows cleaner error messages in "
844846
"applications that convert between exception types::"
845-
msgstr""
847+
msgstr"PEP 409 引入了允许禁用串连的异常上下文显示的新语法。 这允许在不同异常类型间进行转换的应用程序具有更清晰的错误消息::"
846848

847849
#:../../whatsnew/3.3.rst:475
848850
msgid""
@@ -861,12 +863,26 @@ msgid ""
861863
" File\"<stdin>\", line 8, in __getattr__\n"
862864
"AttributeError: x"
863865
msgstr""
866+
">>> class D:\n"
867+
"... def __init__(self, extra):\n"
868+
"... self._extra_attributes = extra\n"
869+
"... def __getattr__(self, attr):\n"
870+
"... try:\n"
871+
"... return self._extra_attributes[attr]\n"
872+
"... except KeyError:\n"
873+
"... raise AttributeError(attr) from None\n"
874+
"...\n"
875+
">>> D({}).x\n"
876+
"Traceback (most recent call last):\n"
877+
" File\"<stdin>\", line 1, in <module>\n"
878+
" File\"<stdin>\", line 8, in __getattr__\n"
879+
"AttributeError: x"
864880

865881
#:../../whatsnew/3.3.rst:490
866882
msgid""
867883
"Without the ``from None`` suffix to suppress the cause, the original "
868884
"exception would be displayed by default::"
869-
msgstr""
885+
msgstr"如果后面没有 ``from None`` 来屏蔽异常原因,则默认原始异常将被显示::"
870886

871887
#:../../whatsnew/3.3.rst:493
872888
msgid""
@@ -891,6 +907,26 @@ msgid ""
891907
" File\"<stdin>\", line 8, in __getattr__\n"
892908
"AttributeError: x"
893909
msgstr""
910+
">>> class C:\n"
911+
"... def __init__(self, extra):\n"
912+
"... self._extra_attributes = extra\n"
913+
"... def __getattr__(self, attr):\n"
914+
"... try:\n"
915+
"... return self._extra_attributes[attr]\n"
916+
"... except KeyError:\n"
917+
"... raise AttributeError(attr)\n"
918+
"...\n"
919+
">>> C({}).x\n"
920+
"Traceback (most recent call last):\n"
921+
" File\"<stdin>\", line 6, in __getattr__\n"
922+
"KeyError: 'x'\n"
923+
"\n"
924+
"During handling of the above exception, another exception occurred:\n"
925+
"\n"
926+
"Traceback (most recent call last):\n"
927+
" File\"<stdin>\", line 1, in <module>\n"
928+
" File\"<stdin>\", line 8, in __getattr__\n"
929+
"AttributeError: x"
894930

895931
#:../../whatsnew/3.3.rst:514
896932
msgid""

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp