diff -r 1f743bad6fd3 -r cd22e8e705f4 src/eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.MiscellaneousChecker.html --- a/src/eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.MiscellaneousChecker.html Sun Feb 16 15:05:39 2025 +0100 +++ b/src/eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.MiscellaneousChecker.html Sun Feb 16 15:06:29 2025 +0100 @@ -47,6 +47,14 @@ <td>Class to hold the data for a caught exception.</td> </tr> <tr> +<td><a href="#M541UnhandledKeyType">M541UnhandledKeyType</a></td> +<td>Class to hold a dictionary key of a type that we do not check for duplicates.</td> +</tr> +<tr> +<td><a href="#M541VariableKeyType">M541VariableKeyType</a></td> +<td>Class to hold the name of a variable key type.</td> +</tr> +<tr> <td><a href="#M569Checker">M569Checker</a></td> <td>Class traversing a 'for' loop body to check for modifications to a loop's mutable iterable.</td> </tr> @@ -133,7 +141,7 @@ <td>Private method to check for return/continue/break inside finally blocks.</td> </tr> <tr> -<td><a href="#BugBearVisitor.__checkForM513_M529_M530">__checkForM513_M529_M530</a></td> +<td><a href="#BugBearVisitor.__checkForM513_M514_M529_M530">__checkForM513_M514_M529_M530</a></td> <td>Private method to check various exception handler situations.</td> </tr> <tr> @@ -221,6 +229,10 @@ <td>Private method to check the usage of exceptions with added note.</td> </tr> <tr> +<td><a href="#BugBearVisitor.__checkForM541">__checkForM541</a></td> +<td>Private method to check for duplicate key value pairs in a dictionary literal.</td> +</tr> +<tr> <td><a href="#BugBearVisitor.__checkForM569">__checkForM569</a></td> <td>Private method to check for changes to a loop's mutable iterable.</td> </tr> @@ -277,6 +289,10 @@ <td></td> </tr> <tr> +<td><a href="#BugBearVisitor.convertToValue">convertToValue</a></td> +<td>Function to extract the value of a given item.</td> +</tr> +<tr> <td><a href="#BugBearVisitor.emptyBody">emptyBody</a></td> <td></td> </tr> @@ -345,6 +361,10 @@ <td>Public method to handle comparison statements.</td> </tr> <tr> +<td><a href="#BugBearVisitor.visit_Dict">visit_Dict</a></td> +<td>Public method to check a dictionary.</td> +</tr> +<tr> <td><a href="#BugBearVisitor.visit_DictComp">visit_DictComp</a></td> <td>Public method to handle dictionary comprehensions.</td> </tr> @@ -402,7 +422,11 @@ </tr> <tr> <td><a href="#BugBearVisitor.visit_Try">visit_Try</a></td> -<td>Public method to handle 'try' statements'.</td> +<td>Public method to handle 'try' statements.</td> +</tr> +<tr> +<td><a href="#BugBearVisitor.visit_TryStar">visit_TryStar</a></td> +<td>Public method to handle 'except*' statements.</td> </tr> <tr> <td><a href="#BugBearVisitor.visit_UAdd">visit_UAdd</a></td> @@ -495,9 +519,9 @@ reference to the node to be processed </dd> </dl> -<a NAME="BugBearVisitor.__checkForM513_M529_M530" ID="BugBearVisitor.__checkForM513_M529_M530"></a> -<h4>BugBearVisitor.__checkForM513_M529_M530</h4> -<b>__checkForM513_M529_M530</b>(<i>node</i>) +<a NAME="BugBearVisitor.__checkForM513_M514_M529_M530" ID="BugBearVisitor.__checkForM513_M514_M529_M530"></a> +<h4>BugBearVisitor.__checkForM513_M514_M529_M530</h4> +<b>__checkForM513_M514_M529_M530</b>(<i>node</i>) <p> Private method to check various exception handler situations. </p> @@ -841,6 +865,20 @@ reference to the node to be processed </dd> </dl> +<a NAME="BugBearVisitor.__checkForM541" ID="BugBearVisitor.__checkForM541"></a> +<h4>BugBearVisitor.__checkForM541</h4> +<b>__checkForM541</b>(<i>node</i>) +<p> + Private method to check for duplicate key value pairs in a dictionary literal. +</p> + +<dl> + +<dt><i>node</i> (ast.Dict)</dt> +<dd> +reference to the node to be processed +</dd> +</dl> <a NAME="BugBearVisitor.__checkForM569" ID="BugBearVisitor.__checkForM569"></a> <h4>BugBearVisitor.__checkForM569</h4> <b>__checkForM569</b>(<i>node</i>) @@ -857,7 +895,7 @@ </dl> <a NAME="BugBearVisitor.__checkRedundantExcepthandlers" ID="BugBearVisitor.__checkRedundantExcepthandlers"></a> <h4>BugBearVisitor.__checkRedundantExcepthandlers</h4> -<b>__checkRedundantExcepthandlers</b>(<i>names, node</i>) +<b>__checkRedundantExcepthandlers</b>(<i>names, node, inTryStar</i>) <p> Private method to check for redundant exception types in an exception handler. </p> @@ -872,6 +910,10 @@ <dd> reference to the exception handler node </dd> +<dt><i>inTryStar</i> (str)</dt> +<dd> +character indicating an 'except*' handler +</dd> </dl> <dl> <dt>Return:</dt> @@ -1153,6 +1195,32 @@ <h4>BugBearVisitor.check</h4> <b>check</b>(<i>paramName</i>) +<a NAME="BugBearVisitor.convertToValue" ID="BugBearVisitor.convertToValue"></a> +<h4>BugBearVisitor.convertToValue</h4> +<b>convertToValue</b>(<i></i>) +<p> + Function to extract the value of a given item. +</p> + +<dl> + +<dt><i>item</i> (ast.Ast)</dt> +<dd> +node to extract value from +</dd> +</dl> +<dl> +<dt>Return:</dt> +<dd> +value of the node +</dd> +</dl> +<dl> +<dt>Return Type:</dt> +<dd> +Any +</dd> +</dl> <a NAME="BugBearVisitor.emptyBody" ID="BugBearVisitor.emptyBody"></a> <h4>BugBearVisitor.emptyBody</h4> <b>emptyBody</b>(<i></i>) @@ -1374,6 +1442,20 @@ reference to the node to be processed </dd> </dl> +<a NAME="BugBearVisitor.visit_Dict" ID="BugBearVisitor.visit_Dict"></a> +<h4>BugBearVisitor.visit_Dict</h4> +<b>visit_Dict</b>(<i>node</i>) +<p> + Public method to check a dictionary. +</p> + +<dl> + +<dt><i>node</i> (ast.Dict)</dt> +<dd> +reference to the node to be processed +</dd> +</dl> <a NAME="BugBearVisitor.visit_DictComp" ID="BugBearVisitor.visit_DictComp"></a> <h4>BugBearVisitor.visit_DictComp</h4> <b>visit_DictComp</b>(<i>node</i>) @@ -1574,7 +1656,7 @@ <h4>BugBearVisitor.visit_Try</h4> <b>visit_Try</b>(<i>node</i>) <p> - Public method to handle 'try' statements'. + Public method to handle 'try' statements. </p> <dl> @@ -1584,6 +1666,20 @@ reference to the node to be processed </dd> </dl> +<a NAME="BugBearVisitor.visit_TryStar" ID="BugBearVisitor.visit_TryStar"></a> +<h4>BugBearVisitor.visit_TryStar</h4> +<b>visit_TryStar</b>(<i>node</i>) +<p> + Public method to handle 'except*' statements. +</p> + +<dl> + +<dt><i>node</i> (ast.TryStar)</dt> +<dd> +reference to the node to be processed +</dd> +</dl> <a NAME="BugBearVisitor.visit_UAdd" ID="BugBearVisitor.visit_UAdd"></a> <h4>BugBearVisitor.visit_UAdd</h4> <b>visit_UAdd</b>(<i>node</i>) @@ -2154,6 +2250,87 @@ <div align="right"><a href="#top">Up</a></div> <hr /> <hr /> +<a NAME="M541UnhandledKeyType" ID="M541UnhandledKeyType"></a> +<h2>M541UnhandledKeyType</h2> +<p> + Class to hold a dictionary key of a type that we do not check for duplicates. +</p> + +<h3>Derived from</h3> +None +<h3>Class Attributes</h3> +<table> +<tr><td>None</td></tr> +</table> + +<h3>Class Methods</h3> +<table> +<tr><td>None</td></tr> +</table> + +<h3>Methods</h3> +<table> +<tr><td>None</td></tr> +</table> + +<h3>Static Methods</h3> +<table> +<tr><td>None</td></tr> +</table> + + +<div align="right"><a href="#top">Up</a></div> +<hr /> +<hr /> +<a NAME="M541VariableKeyType" ID="M541VariableKeyType"></a> +<h2>M541VariableKeyType</h2> +<p> + Class to hold the name of a variable key type. +</p> + +<h3>Derived from</h3> +None +<h3>Class Attributes</h3> +<table> +<tr><td>None</td></tr> +</table> + +<h3>Class Methods</h3> +<table> +<tr><td>None</td></tr> +</table> + +<h3>Methods</h3> +<table> +<tr> +<td><a href="#M541VariableKeyType.__init__">M541VariableKeyType</a></td> +<td>Constructor</td> +</tr> +</table> + +<h3>Static Methods</h3> +<table> +<tr><td>None</td></tr> +</table> + + +<a NAME="M541VariableKeyType.__init__" ID="M541VariableKeyType.__init__"></a> +<h4>M541VariableKeyType (Constructor)</h4> +<b>M541VariableKeyType</b>(<i>name</i>) +<p> + Constructor +</p> + +<dl> + +<dt><i>name</i> (str)</dt> +<dd> +name of the variable key type +</dd> +</dl> +<div align="right"><a href="#top">Up</a></div> +<hr /> +<hr /> <a NAME="M569Checker" ID="M569Checker"></a> <h2>M569Checker</h2> <p> @@ -2498,7 +2675,7 @@ Private method to check some comprehension related things. </p> <p> - This method is adapted from: flake8-comprehensions v3.15.0 + This method is adapted from: flake8-comprehensions v3.16.0 Original: Copyright (c) 2017 Adam Johnson </p>