File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 1
- {"translation" : " 83.00%" , "updated_at" : " 2025-04-18T01:47:04Z " }
1
+ {"translation" : " 83.00%" , "updated_at" : " 2025-04-18T02:41:06Z " }
Original file line number Diff line number Diff line change @@ -3966,6 +3966,10 @@ msgid ""
3966
3966
"behaviour was intentional can use :func:`inspect.unwrap` to access the first"
3967
3967
" function in the chain that has no ``__wrapped__`` attribute."
3968
3968
msgstr ""
3969
+ "现在 :func:`functools.update_wrapper` 和 :func:`functools.wraps` 会正确地将 "
3970
+ "``__wrapped__`` 属性设为被包装的函数,即使该函数同样设置了 ``__wrapped__`` 属性。 这意味着 "
3971
+ "``__wrapped__`` 属性现在会正确地链接由被装饰函数组成的栈而不是链中指向最内层函数的的每个 ``__wrapped__`` 属性。 "
3972
+ "确定要沿袭之前版本行为的内省库可以使用 :func:`inspect.unwrap` 来访问链中没有 ``__wrapped__`` 属性的第一个函数。"
3969
3973
3970
3974
#: ../../whatsnew/3.4.rst:2329
3971
3975
msgid ""
You can’t perform that action at this time.
0 commit comments