liftoff / pyminifier

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

Problem of python indent (like if) #138

Open ciberneticaDieu opened 1 year ago

ciberneticaDieu commented 1 year ago

The pyminifier can't minify python indent like this: if 1==1:   print("Hi") --pyminifier-->exec(b'if 1==1:\nF=print\n F("Hi")\n') I run into this problem when I run the code minified with pyminifier  link To solve the problem, you can add a tab to your Algorithm. look like that : exec(b'if 1==1:\nF=print\n F("Hi")\n')  --adding tab-->  exec(b'if 1==1:\n\tF=print \n\tF("Hi")')