Open krzysztof3-wisniewski opened 2 years ago
Using flake8-eradicate==1.2.1 On CPython 3.9.13 With flake8==4.0.1 Using the following code as an example
flake8-eradicate==1.2.1
CPython 3.9.13
flake8==4.0.1
class FooClass(SpamClass): def render_html(self) -> str: return f""" <div> <div> <h2> spam content <bold>{self.foo.bar().car()}</bold> to <bold>foo</bold><br/> </h2> <i> “Some quote.” <br/>~Quote author <i/> <div> </div> <table> <tbody> <tr> <td><bold>Foo foo</bold></td> <td>{self.bar.foo}</td> </tr> <tr> <td><bold>Bar foo</bold></td> <td>{self.barbar.foo}</td> </tr> <tr> <td><bold>Foo spam</bold></td> <td> <a href="https://service.com/spam/foo/bar/{self.foo.car}"> #{self.foo.car} <a/> </td> </tr> <tr> <td><bold>Spam bar</bold></td> <td>{self.foo()}</td> </tr> </tbody> </table> </div> </div> """
Following snipped, line #{self.foo.car} generates an error Found commented out code flake8(E800)
#{self.foo.car}
Found commented out code flake8(E800)
<a href="https://service.com/spam/foo/bar/{self.foo.car}"> #{self.foo.car} <a/>
Which, of course, is not correct because we are not dealing with a comment here. Removing the # from the content makes the error disappear, however, this is not the solution.
Using
flake8-eradicate==1.2.1
OnCPython 3.9.13
Withflake8==4.0.1
Using the following code as an exampleFollowing snipped, line
#{self.foo.car}
generates an errorFound commented out code flake8(E800)
Which, of course, is not correct because we are not dealing with a comment here. Removing the # from the content makes the error disappear, however, this is not the solution.