Content-Length: 286975 | pFad | http://github.com/github/codeql/pull/20052/commits/7a7db0efe8854151349e7df58d2a5d0d946d6078

B4 Python: Minor documantation updates to several quality queries by joefarebrother · Pull Request #20052 · github/codeql · GitHub
Skip to content

Python: Minor documantation updates to several quality queries #20052

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update unsupported format character documentaion, fix outdated refere…
…nce link
  • Loading branch information
joefarebrother committed Jul 15, 2025
commit 7a7db0efe8854151349e7df58d2a5d0d946d6078
9 changes: 5 additions & 4 deletions python/ql/src/Expressions/UnsupportedFormatCharacter.qhelp
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,27 @@
"qhelp.dtd">
<qhelp>
<overview>
<p>A format string, that is the string on the left hand side of an expression like <code>fmt % arguments</code>, must consist of legal conversion specifiers.
<p>A printf-style format string (i.e. a string that is used as the left hand side of the <code>%</code> operator, such as <code>fmt % arguments</code>)
must consist of valid conversion specifiers, such as <code>%s</code>, <code>%d</code>, etc.
Otherwise, a <code>ValueError</code> will be raised.

</p>

</overview>
<recommendation>
<p>Choose a legal conversion specifier.</p>
<p>Ensure a valid conversion specifier is used.</p>

</recommendation>
<example>
<p>In <code>format_as_tuple_incorrect</code>, "t" is not a legal conversion specifier.
<p>In the following example, <code>format_as_tuple_incorrect</code>, <code>%t</code> is not a valid conversion specifier.

</p>
<sample src="UnsupportedFormatCharacter.py" />

</example>
<references>

<li>Python Library Reference: <a href="http://docs.python.org/library/stdtypes.html#string-formatting">String Formatting.</a> </li>
<li>Python Library Reference: <a href="https://docs.python.org/3/library/stdtypes.html#printf-style-string-formatting">printf-style String Formatting.</a> </li>

</references>
</qhelp>








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/github/codeql/pull/20052/commits/7a7db0efe8854151349e7df58d2a5d0d946d6078

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy