W0105 pointless-string-statement¶
- Message
'String statement has no effect'
- Description
Used when a string is used as a statement (which of course has no effect). This is a particular case of W0104 with its own message so you can easily disable it if you’re using those strings as documentation, instead of comments.
Example¶
In the following example, the statement on line 3 does not have an effect. It can safely be removed.
def fn():
something = 1
"something"
return something
3:4: W0105: String statement has no effect
Running Pylint locally? In your CI?
There is a better way! Run PyCodeQual & get Pylint findings with history, diffs and statistics.

Click here to find out more.