Python Forum
.pyc -> .py - to check if my code was used
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
.pyc -> .py - to check if my code was used
#1
i would like to know what facilities might exist to translate a .pyc file back to some form of python source.

here's my case:

i found a package installed on my computer that i had not installed.  so maybe it was a dependency of something else, although i cannot find any references in all of the files in /etc, /usr, and /var.  the thing that attracted my attention to this package was the combination of some kind of packaging description files and it having the same name as some code i write and put online.  further, there was the oddity, that these packaging description files are dated just one day after i released my code.  i am not considering this as stolen since i released my code under an MIT-like license.  this package appears to have only a .pyc file.  the name is not found under pip or apt-get (for Ubuntu).  but i am curious if my code was used.

here is my code:
http://linuxhomepage.com/free/columnize.py

here is a gzipped tarball of the package files i found on my laptop:
http://linuxhomepage.com/free/columnize-0.3.9.tar.gz

if i could just get some idea of the order of logic they used, it would help. so rough decompiler could help.
Tradition is peer pressure from dead people

What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Reply
#2
possibly (never used it) this: https://pypi.python.org/pypi/uncompyle6
Reply
#3
Have you checked your links, they are both dead to me (using Chrome). There is this: columnize on PyPi which makes reference to pycolumnize on GitHub. A cursory look at the files only makes reference to a .pyc is in the Makefile:

Quote:# It is too much work to figure out how to add a new command to distutils
# to do the following. I'm sure distutils will someday get there.
DISTCLEAN_FILES = build dist *.egg-info *.pyc *.so py*.py
If it ain't broke, I just haven't gotten to it yet.
OS: Windows 10, openSuse 42.3, freeBSD 11, Raspian "Stretch"
Python 3.6.5, IDE: PyCharm 2018 Community Edition
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020