Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Pycompall is a wrapper around the default `compileall` Python utility to compile `.py` to `.pyc` files to provide a more configurable interface and as a build tool when configuring python files.
Pycompall is a wrapper around the default compileall
Python utility to compile .py
to .pyc
files to provide a more configurable interface and as a build tool when configuring python files.
This package is also useful for code obfuscation, especially since most .py
files can be substituted for their compiled bytecode equivalents most of the time.
pip install pycompall
pycompall compile [OPTIONS] [PATH]
.
Without any options, this will compile all .py
files in the current directory (or file) into the default __pycache__
directory.
-r
, --recursive
Recurse through subdirectories.
--in-place
Remove original .py
files and replace them with compiled .pyc
files.
--create-empty-init
Create an empty __init__.py
file in the base directory path specified after compilation. Useful for interacting with other build tools such as colcon that require a package to have an __init__.py
file.
--recursive
flag is specified.--exclude-files TEXT
Exclude pattern(s) for files to be excluded during compilation and replacement.
Path.match
method, but this requires globs to be passed as strings to the tool, so you must wrap the glob in quotes (e.g. pycompall compile --exclude-files '*.py'
).pycompall compile --exclude-files '*test.py' --exclude-files 'test/*.py'
)--exclude-dirs TEXT
Exclude pattern(s) for directories to be excluded during compilation and replacement. Note that if the directory is skipped and --create-empty-init is True, the __init__.py
file will not be created.
Path.match
method, but this requires globs to be passed as strings to the tool, so you must wrap the glob in quotes (e.g. pycompall compile --exclude-dirs 'test*'
).pycompall compile --exclude-dirs 'test' --exclude-dirs 'utils'
)--ignore-symlinks
Sometimes symlinks causes problems. Enable this flag to ignore symlinks.
FAQs
Pycompall is a wrapper around the default `compileall` Python utility to compile `.py` to `.pyc` files to provide a more configurable interface and as a build tool when configuring python files.
We found that pycompall demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.