pyc转py工具

    科技2025-05-22  37

    uncompyle6

    https://github.com/rocky/python-uncompyle6/

    遍历目录下所有pyc文件并转换

    实际上有很多文件不能解析出来。尚不知为何原因

     

    import os def filelist(dir): print(dir) for home, dirs, files in os.walk(dir): for filename in files: #print(filename) if os.path.splitext(filename)[-1] == ".pyc": dest_file = os.path.join(home, os.path.splitext(filename)[0]+'.py') src_file = os.path.join(home, filename) print(dest_file) print(src_file) os.system('uncompyle6 -o '+dest_file+' '+src_file) if __name__ == '__main__': filelist("D:\\tool")

     python中序列化和反序列化

    https://www.cnblogs.com/bigtreei/p/10466518.html

     

      

     

    Processed: 0.010, SQL: 8