229 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
Tooling
0
votes
1
replies
36
views
python pex to distribute a project
I have a python project and want to distribute it as a single file. I found PEX but found it difficult to use. Initially, I thought if my project is in a folder like the following
<folder>\
...
0
votes
0
answers
130
views
PEX Build Fails Due to Missing manylinux_2_17 or manylinux_2_27 Wheels for numpy and pandas on Python 3.12
I’m building a PEX file for a Python 3.12 project (system-monitor) targeting Amazon Linux 2023 (glibc 2.34) on both x86_64 and aarch64 architectures. I’m using PEX with --platform options to enforce ...
0
votes
1
answer
25
views
Get name of executed .pex file?
Consider this script /tmp/test.py:
import os
import sys
print(__file__)
print(os.path.dirname(os.path.realpath(__file__)))
print(sys.argv)
bundled like this with pex:
python -m pex --exe test.py -o ...
0
votes
1
answer
192
views
Is possible to read environment variables while running python code on a PEX file?
I am trying to have my python application running on a PEX file, inside a docker container.
I was wondering if PEX files support any kind of configuration in order to read environment variables that ...
1
vote
1
answer
719
views
pex built by pex doesn't run outside its virtualenv
TL;DR
I built pex according to the guide https://pex.readthedocs.io/en/v2.1.145/buildingpex.html and was expecting it to run fine outside of the virtualenv I used to build it, but alas:
$ ~/bin/pex
...
-1
votes
1
answer
83
views
Unable to find html file in pex executable
Hello I will try to define my issue:
I have created a pex file with follow commnad:
$ pex --disable-cache . -e ${PYTHON_ENTRYPOINT} -o app.pex -R utils/tasks/templates
And I have my files as:
So ...
0
votes
1
answer
294
views
Using python pex as interpreter doesn't work
I have a python pex file that I want to use as a python interpreter. I set the .pex in vscode as python interpreter and vscode recognized it correctly as python interpreter, but when I click on run, ...
1
vote
1
answer
593
views
I am unable to create a pex file with a custom pacakge inside
I was following this tutorial to add my own pacakge to .pex but this tutorial is based on python2 and I try to recreate for python3.10.6 but does not works.
The structure of my package is as follow ...
5
votes
0
answers
830
views
Databricks PySpark with PEX: how can I configure a PySpark job on Databricks using PEX for dependencies?
I am attempting to create a PySpark job via the Databricks UI (with spark-submit) using the spark-submit parameters below (dependencies are on the PEX file), but I am getting an exception that the PEX ...
0
votes
0
answers
1k
views
aiobotocore==2.3.4 requires botocore<1.24.22,>=1.24.21 but botocore 1.27.55 was resolved
I am getting the below error while I'm trying to build pex file on a remote server and I'm putting boto3 in my requirements.txt and not botocore or aioboto in my file but still getting this
...
0
votes
0
answers
590
views
Python - Building pex executables (specifically including 3rd party python libs) for QNX OS machines
Trying to deploy a small python web server to run on a Machine with QNX7.1 OS installed.
For various reasons, I cannot use docker, Pip is also not available on the machine nor can I just pre-install ...
0
votes
1
answer
120
views
Intellitest Pex Parameterize Mock
public enum SystemConstants
{
SystemTypeDocument,
ApplicationTypeDocument
}
public interface ISystemBaseObject
{
SystemConstants SystemType();
}
public class ExploreMockExample
{...
0
votes
1
answer
1k
views
Problems creating entrypoint on PEX file
I am currently trying to create a pex file with an Pythonfile entrypoint.
My Folder structure looks like the following:
├── readme.md
├── requirements.txt
├── setup.py
├── stv
│ ├── adminuser.py
│ ...
1
vote
2
answers
2k
views
pyyaml dependency error while executing with python script in PEX
I am getting the following error while trying to package and execute a script with PEX.
Failed to execute PEX file. Needed macosx_10_14_x86_64-cp-38-cp38 compatible dependencies for:
1: pyyaml
...
1
vote
1
answer
3k
views
Select a custom python environment/version in pex file
in my environment I have python 3.8.5 and pex 2.1.20
I'm bundling some libraries in a pex file with this command:
pex module1 module2 module3 -o custom_env.pex
The reason being that I want to ...