percevalw / pygetsource

A decompiler for Python 3
MIT License
2 stars 0 forks source link

can you give an example how to use pygetsource decompile pyc files plz #4

Open Sirin112 opened 1 year ago

percevalw commented 1 year ago

Hi, This project is still in active development, and most .pyc decompilation attempts are likely to fail due to the lack of support for classes, try/except/with/yield/async syntaxes. Indeed, atm, the project works for small functions but not full files. Furthermore, .pyc objects contain header that I've not taken into account yet. You can still try by following https://stackoverflow.com/questions/25126282/marshal-loads-function-does-not-load-pyc-contents-to-code-object to load an .pyc into a code object and decompiling it with getsource. Good luck !