GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — python-docs-ru/library/asyncio-tools.po at 3.14 · python/python-docs-ru Expand file tree/ Copy pathasyncio-tools.poMore file actions 213 lines (190 loc) · 7.7 KB / Copy pathasyncio-tools.poFile metadata and controls213 lines (190 loc) · 7.7 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 # SOME DESCRIPTIVE TITLE. # Copyright (C) 2001 Python Software Foundation # This file is distributed under the same license as the Python package. # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. # # Translators: # python-doc bot, 2026 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.15\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2026-11-01 18:39+0000\n" "PO-Revision-Date: 2026-07-11 14:48+0000\n" "Last-Translator: python-doc bot, 2026\n" "Language-Team: Russian (https://app.transifex.com/python-doc/teams/5390/" "ru/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Language: ru\n" "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && " "n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || " "(n%100>=11 && n%100<=14)? 2 : 3);\n" msgid "Command-line introspection tools" msgstr "" msgid "**Source code:** :source:`Lib/asyncio/tools.py`" msgstr "" msgid "" "The :mod:`!asyncio` module can be invoked as a script via ``python -m " "asyncio`` to inspect the task graph of another running Python process " "without modifying it or restarting it. The :mod:`!asyncio.tools` submodule " "implements this interface." msgstr "" msgid "The following commands inspect the process identified by ``PID``:" msgstr "" msgid "" "$ python -m asyncio pstree [--retries N] PID\n" "$ python -m asyncio ps [--retries N] PID" msgstr "" msgid "" "The commands read the target process state without executing any code in it. " "They are only available on supported platforms and may require permission to " "inspect another process. See the :ref:`permission requirements <permission-" "requirements>` for details." msgstr "" msgid ":ref:`asyncio-graph`" msgstr "" msgid "" "Programmatic APIs for inspecting the async call graph of a task or future in " "the current process." msgstr "" msgid "" "The command examples below use this program, which creates a task hierarchy " "suitable for inspection and prints its process ID:" msgstr "" msgid "example.py" msgstr "" msgid "" "import asyncio\n" "import os\n" "\n" "async def play(track):\n" " await asyncio.sleep(3600)\n" " print(f\"🎵 Finished: {track}\")\n" "\n" "async def album(name, tracks):\n" " async with asyncio.TaskGroup() as tg:\n" " for track in tracks:\n" " tg.create_task(play(track), name=track)\n" "\n" "async def main():\n" " print(f\"PID: {os.getpid()}\")\n" " async with asyncio.TaskGroup() as tg:\n" " tg.create_task(\n" " album(\"Sundowning\", [\"TNDNBTG\", \"Levitate\"]),\n" " name=\"Sundowning\",\n" " )\n" " tg.create_task(\n" " album(\"TMBTE\", [\"DYWTYLM\", \"Aqua Regia\"]),\n" " name=\"TMBTE\",\n" " )\n" "\n" "asyncio.run(main())" msgstr "" msgid "Run the program in one terminal and leave it running:" msgstr "" msgid "" "$ python example.py\n" "PID: 12345" msgstr "" msgid "" "Then pass the printed process ID to the commands from another terminal. " "Thread IDs, task IDs, file paths, and line numbers vary between runs and " "source layouts." msgstr "" msgid "Command-line options" msgstr "" msgid "" "Display task and coroutine relationships as a tree. Each task is shown with " "its full coroutine stack, nested under the task (if any) that is awaiting " "it. This subcommand is useful for quickly identifying which branch of a " "task hierarchy is blocked and where in its coroutine stack execution has " "paused:" msgstr "" msgid "" "$ python -m asyncio pstree 12345\n" "└── (T) Task-1\n" " └── main example.py:12\n" " └── TaskGroup.__aexit__ Lib/asyncio/taskgroups.py:75\n" " └── TaskGroup._aexit Lib/asyncio/taskgroups.py:124\n" " ├── (T) Sundowning\n" " │ └── album example.py:7\n" " │ └── TaskGroup.__aexit__ Lib/asyncio/" "taskgroups.py:75\n" " │ └── TaskGroup._aexit Lib/asyncio/" "taskgroups.py:124\n" " │ ├── (T) TNDNBTG\n" " │ │ └── play example.py:4\n" " │ │ └── sleep Lib/asyncio/tasks.py:702\n" " │ └── (T) Levitate\n" " │ └── play example.py:4\n" " │ └── sleep Lib/asyncio/tasks.py:702\n" " └── (T) TMBTE\n" " └── album example.py:7\n" " └── TaskGroup.__aexit__ Lib/asyncio/" "taskgroups.py:75\n" " └── TaskGroup._aexit Lib/asyncio/" "taskgroups.py:124\n" " ├── (T) DYWTYLM\n" " │ └── play example.py:4\n" " │ └── sleep Lib/asyncio/tasks.py:702\n" " └── (T) Aqua Regia\n" " └── play example.py:4\n" " └── sleep Lib/asyncio/tasks.py:702" msgstr "" msgid "" "If the await graph contains a cycle, ``pstree`` reports an error instead of " "printing a tree. A cycle in the await graph is unusual and typically " "indicates a programming error:" msgstr "" msgid "" "$ python -m asyncio pstree 12345\n" "ERROR: await-graph contains cycles - cannot print a tree!\n" "\n" "cycle: Task-2 → Task-3 → Task-2" msgstr "" msgid "" "Display a flat table of all pending tasks in the process *PID*. Each row " "shows the event-loop thread ID, task ID and name, coroutine stack, and the " "awaiting task's stack, name, and ID, if any." msgstr "" msgid "" "This subcommand prints all tasks regardless of whether the await graph " "contains cycles:" msgstr "" msgid "" "$ python -m asyncio ps 12345\n" "tid task id task name coroutine " "stack awaiter " "chain awaiter name awaiter id\n" "------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------\n" "18445801 0x10a456060 Task-1 TaskGroup._aexit -> " "TaskGroup.__aexit__ -> " "main " "0x0\n" "18445801 0x10a439f60 Sundowning TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album TaskGroup._aexit -> TaskGroup.__aexit__ -> " "main Task-1 0x10a456060\n" "18445801 0x10a439d70 TMBTE TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album TaskGroup._aexit -> TaskGroup.__aexit__ -> " "main Task-1 0x10a456060\n" "18445801 0x10a2a3a80 TNDNBTG sleep -> " "play TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album Sundowning 0x10a439f60\n" "18445801 0x10a2a38a0 Levitate sleep -> " "play TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album Sundowning 0x10a439f60\n" "18445801 0x10a2d7150 DYWTYLM sleep -> " "play TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album TMBTE 0x10a439d70\n" "18445801 0x10a6bdaa0 Aqua Regia sleep -> " "play TaskGroup._aexit -> " "TaskGroup.__aexit__ -> album TMBTE 0x10a439d70" msgstr "" msgid "" "Retry failed attempts to inspect the target process up to *N* times. This " "can help when the target process changes while its state is being read." msgstr "" |
| You are visitor 01402520 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |