Falldog / pyconcrete

Protect your python script, encrypt it as .pye and decrypt when import it
Apache License 2.0
702 stars 150 forks source link

pyconcrete in venv #56

Closed zbynekdrlik closed 1 year ago

zbynekdrlik commented 5 years ago

It is not possible install pyconcrete under armbian in the venv. Setuptools, wheels are upgraded.

Installing collected packages: pyconcrete
  Running setup.py install for pyconcrete ... error
    ERROR: Complete output from command /home/ft5000/devel/webft/venv/bin/python3 -u -c 'import setuptools, tokenize;__file__='"'"'/tmp/pip-install-3ibr09ow/pyconcrete/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-bt822zc5/install-record.txt --single-version-externally-managed --compile --install-headers /home/ft5000/devel/webft/venv/include/site/python3.6/pyconcrete '--passphrase=<your passphrase>':
    ERROR: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
       or: -c --help [cmd1 cmd2 ...]
       or: -c --help-commands
       or: -c cmd --help

    error: option --single-version-externally-managed not recognized
    ----------------------------------------
ERROR: Command "/home/ft5000/devel/webft/venv/bin/python3 -u -c 'import setuptools, tokenize;__file__='"'"'/tmp/pip-install-3ibr09ow/pyconcrete/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-bt822zc5/install-record.txt --single-version-externally-managed --compile --install-headers /home/ft5000/devel/webft/venv/include/site/python3.6/pyconcrete '--passphrase=<your passphrase>'" failed with error code 1 in /tmp/pip-install-3ibr09ow/pyconcrete/
ghost commented 5 years ago

Confirming:

pip3 install pyconcrete==0.12.1 --install-option="--passphrase=UsTmQvJyuq+uVptoAHhmQAH6b+id1Izreif+cGbWOWY="
/home/user1/.local/lib/python3.6/site-packages/pip/_internal/commands/install.py:244: UserWarning: Disabling all use of wheels due to the use of --build-options / --global-options / --install-options.
  cmdoptions.check_install_build_global(options)
Collecting pyconcrete==0.12.1
  Using cached https://files.pythonhosted.org/packages/a5/be/2bf8d1edc9a0688d5f9be89495d263566f30b50b368256fc9602685793cd/pyconcrete-0.12.1.tar.gz
Skipping bdist_wheel for pyconcrete, due to binaries being disabled for it.
Installing collected packages: pyconcrete
  Running setup.py install for pyconcrete ... error
    ERROR: Complete output from command /usr/bin/python3 -u -c 'import setuptools, tokenize;__file__='"'"'/tmp/pip-install-supqosrz/pyconcrete/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-dsm0f5oh/install-record.txt --single-version-externally-managed --compile '--passphrase=<UsTmQvJyuq+uVptoAHhmQAH6b+id1Izreif+cGbWOWY=>':
    ERROR: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
       or: -c --help [cmd1 cmd2 ...]
       or: -c --help-commands
       or: -c cmd --help

    error: option --single-version-externally-managed not recognized
    ----------------------------------------
ERROR: Command "/usr/bin/python3 -u -c 'import setuptools, tokenize;__file__='"'"'/tmp/pip-install-supqosrz/pyconcrete/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-dsm0f5oh/install-record.txt --single-version-externally-managed --compile '--passphrase=<UsTmQvJyuq+uVptoAHhmQAH6b+id1Izreif+cGbWOWY=>'" failed with error code 1 in /tmp/pip-install-supqosrz/pyconcrete/
Aditya715 commented 5 years ago

Install the package offline or install the package by using the --egg. I'm using pyconcrete in venv as well as virtualenv since a long time.

allista commented 5 years ago

pip 19.2.3

> pip install pyconcrete --egg
no such option: --egg
Aditya715 commented 5 years ago

@allista Install using the github package. Clone the falldog/pyconcrete repository. If using venv, activate the venv else do the rest steps. go inside the pyconcrete directory... > cd pyconcrete Then simply run.... python setup.py install It will ask a passphrase.... Provide it then enter then re-enter the passphrase. It will install pyconcrete in your venv or in your base machine. Hope you'll get it done