msgid"asyncio has powerful runtime call graph introspection utilities to trace the entire call graph of a running *coroutine* or *task*, or a suspended *future*. These utilities and the underlying machinery can be used from within a Python program or by external profilers and debuggers."
msgstr"asyncio ابزارهای قدرتمند دروننگری نمودار فراخوانی در رانتایم دارد که برای ردگیری کل نمودار فراخوانی یک *همروال* یا *وظیفه* در حال اجرا، یا یک *آینده* معلق به کار میروند. میتوان از این ابزارها و سازوکار زیربنایی، از درون یک برنامه پایتون یا بهوسیله پروفایلگیرها و اشکالزداهای خارجی استفاده کرد."
msgid":ref:`asyncio-introspection-tools`"
msgstr":ref:`asyncio-introspection-tools`"
msgid"Command-line tools for inspecting tasks in another running Python process."
msgstr"ابزارهای خط فرمان برای بازرسی وظایف در فرایند پایتون دیگری که در حال اجرا است."
msgid"Print the async call graph for the current task or the provided :class:`Task` or :class:`Future`."
msgstr"گراف فراخوانی ناهمگام برای وظیفه فعلی یا :class:`Task` یا :class:`Future` ارائهشده را چاپ میکند."
msgid"This function prints entries starting from the top frame and going down towards the invocation point."
msgstr"این تابع مدخلها را از فریم بالایی تا نقطه فراخوانی به ترتیب رو به پایین چاپ میکند."
msgid"The function receives an optional *future* argument. If not passed, the current running task will be used."
msgstr"این تابع یک آرگومان اختیاری *future* دریافت میکند. اگر ارسال نشود، از وظیفه در حال اجرای فعلی استفاده خواهد شد."
msgid"If the function is called on *the current task*, the optional keyword-only *depth* argument can be used to skip the specified number of frames from top of the stack."
msgstr"اگر تابع روی *وظیفه جاری* فراخوانی شود، میتوانید از آرگومان اختیاری و فقط کلیدواژهای *depth* برای رد کردن تعداد مشخصی از فریمها از بالای پشته استفاده کنید."
msgid"If the optional keyword-only *limit* argument is provided, each call stack in the resulting graph is truncated to include at most ``abs(limit)`` entries. If *limit* is positive, the entries left are the closest to the invocation point. If *limit* is negative, the topmost entries are left. If *limit* is omitted or ``None``, all entries are present. If *limit* is ``0``, the call stack is not printed at all, only \"awaited by\" information is printed."
msgstr"اگر آرگومان اختیاری فقط کلیدواژهای *limit* ارائه شود، هر پشته فراخوانی در گراف حاصل بهگونهای کوتاه میشود که حداکثر شامل ``abs(limit)`` ورودی باشد. اگر *limit* مثبت باشد، ورودیهای باقیمانده نزدیکترین ورودیها به نقطه فراخوانی هستند. اگر *limit* منفی باشد، بالاترین ورودیها باقی میمانند. اگر *limit* ذکر نشود یا ``None`` باشد، همه ورودیها موجود خواهند بود. اگر *limit* برابر ``0`` باشد، پشته فراخوانی اصلاً چاپ نمیشود و فقط اطلاعات «awaited by» چاپ میشود."
msgid"If *file* is omitted or ``None``, the function will print to :data:`sys.stdout`."
msgstr"اگر *file* حذف شود یا ``None`` باشد، تابع در :data:`sys.stdout` چاپ خواهد کرد."
msgid"**Example:**"
msgstr"**مثال:**"
msgid"The following Python code:"
msgstr"کد پایتون زیر:"
msgid""
"import asyncio\n"
"\n"
"async def test():\n"
" asyncio.print_call_graph()\n"
"\n"
"async def main():\n"
" async with asyncio.TaskGroup() as g:\n"
" g.create_task(test(), name='test')\n"
"\n"
"asyncio.run(main())"
msgstr""
"import asyncio\n"
"\n"
"async def test():\n"
" asyncio.print_call_graph()\n"
"\n"
"async def main():\n"
" async with asyncio.TaskGroup() as g:\n"
" g.create_task(test(), name='test')\n"
"\n"
"asyncio.run(main())"
msgid"will print::"
msgstr"چاپ خواهد شد::"
msgid""
"* Task(name='test', id=0x1039f0fe0)\n"
"+ Call stack:\n"
"| File 't2.py', line 4, in async test()\n"
"+ Awaited by:\n"
" * Task(name='Task-1', id=0x103a5e060)\n"
" + Call stack:\n"
" | File 'taskgroups.py', line 107, in async TaskGroup.__aexit__()\n"
" | File 't2.py', line 7, in async main()"
msgstr""
"* Task(name='test', id=0x1039f0fe0)\n"
"+ Call stack:\n"
"| File 't2.py', line 4, in async test()\n"
"+ Awaited by:\n"
" * Task(name='Task-1', id=0x103a5e060)\n"
" + Call stack:\n"
" | File 'taskgroups.py', line 107, in async TaskGroup.__aexit__()\n"
" | File 't2.py', line 7, in async main()"
msgid"Like :func:`print_call_graph`, but returns a string. If *future* is ``None`` and there's no current task, the function returns an empty string."
msgstr"مانند :func:`print_call_graph`، اما یک رشته برمیگرداند. اگر *future* برابر ``None`` باشد و هیچ وظیفه جاریای وجود نداشته باشد، تابع یک رشته خالی برمیگرداند."
msgid"Capture the async call graph for the current task or the provided :class:`Task` or :class:`Future`."
msgstr"گراف فراخوانی ناهمگام برای وظیفه جاری یا :class:`Task` یا :class:`Future` ارائهشده را ضبط کنید."
msgid"The function receives an optional *future* argument. If not passed, the current running task will be used. If there's no current task, the function returns ``None``."
msgstr"این تابع یک آرگومان اختیاری *future* دریافت میکند. اگر ارسال نشود، از وظیفه در حال اجرای فعلی استفاده میشود. اگر وظیفه فعلی وجود نداشته باشد، تابع ``None`` را برمیگرداند."
msgid"Returns a ``FutureCallGraph`` data class object:"
msgstr"یک شیء از دیتاکلاس ``FutureCallGraph`` برمیگرداند:"
msgid"Where *future* is a reference to a :class:`Future` or a :class:`Task` (or their subclasses.)"
msgstr"که در آن *future* ارجاعی به یک :class:`Future` یا :class:`Task` (یا زیرکلاسهای آنها) است."
msgid"``call_stack`` is a tuple of ``FrameCallGraphEntry`` objects."
msgstr"``call_stack`` یک تاپل از اشیای ``FrameCallGraphEntry`` است."
msgid"``awaited_by`` is a tuple of ``FutureCallGraph`` objects."
msgstr"``awaited_by`` تاپلی از اشیای ``FutureCallGraph`` است."
msgid"``FrameCallGraphEntry(frame)``"
msgstr"``FrameCallGraphEntry(frame)``"
msgid"Where *frame* is a frame object of a regular Python function in the call stack."
msgstr"که در آن *frame* یک شیء فریم از یک تابع معمولی پایتون در پشته فراخوانی است."
msgid"Low level utility functions"
msgstr"توابع سودمند سطح پایین"
msgid"To introspect an async call graph asyncio requires cooperation from control flow structures, such as :func:`shield` or :class:`TaskGroup`. Any time an intermediate :class:`Future` object with low-level APIs like :meth:`Future.add_done_callback() <asyncio.Future.add_done_callback>` is involved, the following two functions should be used to inform asyncio about how exactly such intermediate future objects are connected with the tasks they wrap or control."
msgstr"برای دروننگری گراف فراخوانی ناهمگام، asyncio به همکاری ساختارهای کنترل جریان، مانند :func:`shield` یا :class:`TaskGroup` نیاز دارد. هر زمان که یک شیء میانی :class:`Future` با APIهای سطح پایین مانند :meth:`Future.add_done_callback() <asyncio.Future.add_done_callback>` دخیل باشد، باید از دو تابع زیر استفاده کنید تا asyncio را از چگونگی دقیق اتصال چنین اشیای میانی Future به وظایفی که آنها را پوشش میدهند یا کنترل میکنند مطلع کنید."
msgid"Record that *future* is awaited on by *waiter*."
msgstr"ثبت میکند که *future* توسط *waiter* await میشود."
msgid"Both *future* and *waiter* must be instances of :class:`Future` or :class:`Task` or their subclasses, otherwise the call would have no effect."
msgstr"هر دو *future* و *waiter* باید نمونههایی از :class:`Future` یا :class:`Task` یا زیرکلاسهای آنها باشند، در غیر این صورت این فراخوانی هیچ اثری نخواهد داشت."
msgid"A call to ``future_add_to_awaited_by()`` must be followed by an eventual call to the :func:`future_discard_from_awaited_by` function with the same arguments."
msgstr"فراخوانی ``future_add_to_awaited_by()`` باید در نهایت با فراخوانی تابع :func:`future_discard_from_awaited_by` با همان آرگومانها دنبال شود."
msgid"Record that *future* is no longer awaited on by *waiter*."
msgstr"ثبت کنید که *future* دیگر توسط *waiter* await نمیشود."