Browse Source

Exceptions, Input

pull/102/merge
Jure Šorn 1 month ago
parent
commit
078178902e
3 changed files with 5 additions and 5 deletions
  1. 4
      README.md
  2. 4
      index.html
  3. 2
      parse.js

4
README.md

@ -1461,7 +1461,7 @@ BaseException
| +-- ConnectionError # Errors such as BrokenPipeError/ConnectionAbortedError.
+-- RuntimeError # Raised by errors that don't fall into other categories.
| +-- NotImplementedEr… # Can be raised by abstract methods or by unfinished code.
| +-- RecursionError # Raised when the maximum recursion depth is exceeded.
| +-- RecursionError # Raised if max recursion depth is exceeded (3k by default).
+-- StopIteration # Raised when an empty iterator is passed to next().
+-- TypeError # When an argument of the wrong type is passed to function.
+-- ValueError # When argument has the right type but inappropriate value.
@ -1528,7 +1528,7 @@ Input
```
* **Reads a line from the user input or pipe if present (trailing newline gets stripped).**
* **If argument is passed, it gets printed to the standard output before input is read.**
* **EOFError is raised if user hits EOF (ctrl-d/ctrl-z⏎) or input stream gets exhausted.**
* **EOFError is raised if user hits EOF (ctrl-d/ctrl-z⏎) or if input stream is exhausted.**
Command Line Arguments

4
index.html

@ -1257,7 +1257,7 @@ error_msg = <span class="hljs-string">''</span>.join(traceback.format_exception(
│ └── ConnectionError <span class="hljs-comment"># Errors such as BrokenPipeError/ConnectionAbortedError.</span>
├── RuntimeError <span class="hljs-comment"># Raised by errors that don't fall into other categories.</span>
│ ├── NotImplementedEr… <span class="hljs-comment"># Can be raised by abstract methods or by unfinished code.</span>
│ └── RecursionError <span class="hljs-comment"># Raised when the maximum recursion depth is exceeded.</span>
│ └── RecursionError <span class="hljs-comment"># Raised if max recursion depth is exceeded (3k by default).</span>
├── StopIteration <span class="hljs-comment"># Raised when an empty iterator is passed to next().</span>
├── TypeError <span class="hljs-comment"># When an argument of the wrong type is passed to function.</span>
└── ValueError <span class="hljs-comment"># When argument has the right type but inappropriate value.</span>
@ -1310,7 +1310,7 @@ pprint(&lt;collection&gt;, width=<span class="hljs-number">80</span>, depth=<spa
<ul>
<li><strong>Reads a line from the user input or pipe if present (trailing newline gets stripped).</strong></li>
<li><strong>If argument is passed, it gets printed to the standard output before input is read.</strong></li>
<li><strong>EOFError is raised if user hits EOF (ctrl-d/ctrl-z⏎) or input stream gets exhausted.</strong></li>
<li><strong>EOFError is raised if user hits EOF (ctrl-d/ctrl-z⏎) or if input stream is exhausted.</strong></li>
</ul>
<div><h2 id="commandlinearguments"><a href="#commandlinearguments" name="commandlinearguments">#</a>Command Line Arguments</h2><pre><code class="python language-python hljs"><span class="hljs-keyword">import</span> sys
scripts_path = sys.argv[<span class="hljs-number">0</span>]

2
parse.js

@ -476,7 +476,7 @@ const DIAGRAM_7_B =
" │ └── ConnectionError <span class='hljs-comment'># Errors such as BrokenPipeError/ConnectionAbortedError.</span>\n" +
" ├── RuntimeError <span class='hljs-comment'># Raised by errors that don't fall into other categories.</span>\n" +
" │ ├── NotImplementedEr… <span class='hljs-comment'># Can be raised by abstract methods or by unfinished code.</span>\n" +
" │ └── RecursionError <span class='hljs-comment'># Raised when the maximum recursion depth is exceeded.</span>\n" +
" │ └── RecursionError <span class='hljs-comment'># Raised if max recursion depth is exceeded (3k by default).</span>\n" +
" ├── StopIteration <span class='hljs-comment'># Raised when an empty iterator is passed to next().</span>\n" +
" ├── TypeError <span class='hljs-comment'># When an argument of the wrong type is passed to function.</span>\n" +
" └── ValueError <span class='hljs-comment'># When argument has the right type but inappropriate value.</span>\n";

Loading…
Cancel
Save