liftoff / pyminifier

Pyminifier is a Python code minifier, obfuscator, and compressor.
GNU General Public License v3.0
1.43k stars 221 forks source link

Common Exception pattern is not handled #129

Open liam-ly opened 2 years ago

liam-ly commented 2 years ago
class MyApplicationException(Exception):
    """My custom exception."""

def foo():
    raise MyApplicationException()

is minified into

class MyApplicationException(Exception):
def foo():
 raise MyApplicationException()

I can work around this using pass, but pylint by default will mark this as a lint: https://github.com/PyCQA/pylint/issues/2208