Questions tagged [python]

Python is a dynamically and strongly typed programming language that encourages readability.

Filter by
Sorted by
Tagged with
0
votes
1answer
19 views

Python script keeps getting killed

I run a python script on VPS and I have problem that script keeps getting killed. I had this problem already with 2GB RAM server config, then I upgraded to 4 GB and it seemed to fix the problem (at ...
0
votes
0answers
20 views

MAC os not loading the modules of python in jenkins, how to fix that?

When I ran the python scripts directly, it is able to detect modules of python. But when I ran with jenkins, even the default OS module is not being detected. Any suggestions on how to fix that?
0
votes
0answers
6 views

'DocumentReference' object has no attribute 'push'

I'm writing an app in Python that used Firestore/Firebase! I've got the database all set up. Now I've managed to add an account number into the database see below. Now each time the program runs it ...
0
votes
1answer
34 views

How to combine YAMLfiles in Python?

I have some Kubernetes YAML files which need to combined. For that I tried using Python. Second file (sample.yaml) should be merged to the first file source.yaml Like, the source.yaml has one section ...
-2
votes
1answer
26 views

Problems after trying to upgrade Python

I am still able to run Anaconda, but the Python installation is suffering some issues after accidentally creating a wrong symbolic link and then trying to upgrade Python version The following ...
-1
votes
0answers
66 views

Python sockets: slow or no communication from centos8 linux, while same program from Windows10 works without issue

I'm trying to communicate with a commercial power supply device via TCP/IP using python sockets. I tried using both a virtual linux(centos8stream) and virtual windows10, both running at the same ...
-1
votes
0answers
33 views

Can I do URL re-writing/forwarding using Squid? [closed]

I am trying to do something that I think would be relatively simple. My company is using Artifactory to to mirror PyPi and is curating all of the packages so we only have access to those that are ...
0
votes
1answer
59 views

Why one of the cores is running full on (100%) during development? [closed]

I'm developing an app (Python) which uses face recognition and OpenCV libraries. I can see even after the app finished processing one of the cores keeps running full on for another 10 mins or so. ...
0
votes
0answers
39 views

Apache and Django configuration

I implemented a Django project with MySQL backend. It runs well using python manage.py runserver. Apache seems installed well with no errors. I can access the default apache server. However, I couldn'...
0
votes
1answer
87 views

Ansible: populate new fields in each item of a list

I'm a total Ansible and Python beginner. I have a list: my_items: - name: item1 unix_user: unixuser1 homedir: /home/unixuser2 - name: item2 unix_user: unixuser2 homedir: /home/unixuser2 I ...
-1
votes
0answers
22 views

Why is my site slower after upgrading from Elastic Beanstalk Python 3.6 on 64bit Amazon Linux/2.9.20 to Python 3.8 on 64bit Amazon Linux 2/3.2.1

I don't really know what to add in here (and I know it is a badly phrased question) because I don't know what to try. I am upgrading a Django application on Elastic Beanstalk from from Elastic ...
0
votes
1answer
33 views

Python app IAM service account authentication via Cloud SQL Proxy

Bug Description Hi! I'd like to authenticate as a service account to Google Cloud SQL locally using the CloudSQL Proxy. This is done via a Kubernetes sidecar container pattern with the serviceaccount ...
0
votes
1answer
63 views

Port 8080 not listening when running Gunicorn HTTP server

I am following this tutorial. I installed my app dependencies using pip: pip3 install -r requirements.txt --user Then installed the Gunicorn HTTP server: pip3 install gunicorn --user but when I try ...
0
votes
0answers
106 views

Use SNI with pip/pypi on Ubuntu 14 Trusty

pip no longer works on old versions of Python 2, because https://pypi.python.org/ now requires Server Name Indication (SNI), which isn't available in Python 2.7.6, the version of Python that comes ...
0
votes
0answers
23 views

python make a script that install packages OS for mac/windows/linux

I need to make a python script (python 3), that does I am newbie using python identify the current OS because dev guys work on iPad/surface/windows workstation, Linux servers, some mac minis and so on ...
2
votes
0answers
734 views

Timeout when reading response headers from daemon process. Python, Flask, Apache

I have a problem with my mod_wsgi configuration. Sometimes, I think when there is a lot of traffic on my website, the page breaks and says "Resource temporarily unavailable..." Apache logs: ...
0
votes
1answer
90 views

Static files with Python, Apache (Proxy) and SSL [duplicate]

It's my first question in the community, i apologize in advance if I write something wrong I developed an application in Python (Django) and in the quality environment I am using gunicorn to provide ...
1
vote
0answers
107 views

Invalid Request Block Size with Nginx and USWGI

I am trying to load balance 2 Python apps using Docker and Nginx. App 1 is run using UWSGI and App 2 is run using default Python Server (I used default server for App 2 just for testing purposes. At ...
0
votes
3answers
127 views

Any ideas how could I've been ransomware hacked?

A couple of days ago our clients reported our Solarwinds website was down. So I connected to check through remote desktop and there it was, a fullscreen html-like interface where you could only use ...
0
votes
1answer
86 views

Simple code running in systemd exits to fast?

I had this old code base running in xinet d. It was basically a simple python script that waited for standard in to come in on a socket, it would do something with it and respond on standard out. ...
0
votes
0answers
21 views

How to upgrade from Python 2 to python 3 on Amazon Linux 2?

I created a new AL2 EC2. I see Python 2 is already installed. How can I upgrade this to Python 3 WITHOUT using virtualenv? I would like to maintain ONLY ONE version of Python.
0
votes
0answers
24 views

Openstack authentication failure from python sdk-in jupyter notebook

I have been trying to make a simple connection to Openstack cloud using python-openstack sdk. With no success. Can someone tell me where I am going wrong? I can see that the header is sending ...
0
votes
1answer
69 views

After power failure restart both DNF and YUM stopped working, do nothing, not even metadata check

My environment, happily functioning for a long time, experienced a power outage - of course, the immortal power supply was offline at the time, needing new batteries. As the administrator, I know ...
1
vote
0answers
38 views

Generate systemd task on the fly

I'm writing a script to backup each mysql databases separately on from a mysql server, but instead of handling this inside the script I would like to rely on systemd to generate a backup job to get ...
1
vote
0answers
24 views

Why is my PowerShell script terminating too quickly?

Hoping you can help me I have a very simple python script which sole purpose is to go through a load of excel workbooks and get the data and produce a single file from it. Script works great. I then ...
0
votes
0answers
25 views

Nginx Gunicorn not serving requests to external ip

I have develop a python flask project which is run on linux server. I'm trying to develop it on my linux server. After much effort on this. I have configured nginx, gunicorn and my application. My ...
0
votes
0answers
46 views

Powershell run from Python returns copyright information

I am executing a powershell script using python subprocess module. subprocess.Popen(["powershell.exe","-ExecutionPolicy","bypass","-file","kishore_test.ps1&...
0
votes
2answers
35 views

Is it posible BLOCK windows APPS with a script?

Is it possible to create a script to block certain windows apps in certain periods of time? Something like that in android (when I click on the app, I'm not able of opening it): The purpose of the ...
2
votes
0answers
34 views

RHEL 8.2 podman rootless container network bottleneck at 20Mbits/s

When I run container by podman 1.6.4 on RHEL8.2 (fresh install) with rootless user. The maximum upload speed per container will be around 22Mbits/s (with 1Gbits/s network) After start a second process,...
0
votes
0answers
103 views

php returns error code 127 persistently from exec/shell_exec python script even though script file is found in php by ls-al

I'm using a CentOS x86-64 Linux server, trying to run a python script from a php script called by an html-script. This is a well-covered topic on the internet, however nothing of the instructions and ...
0
votes
0answers
115 views

How to serve a Flask app, static files and other services on the same port using NGINX?

I am trying to serve my Flask app using Nginx. I am able to serve the app using the following server block in my conf.d/test.conf. However when I try to use the application that I have at the ...
0
votes
0answers
82 views

Task Scheduler Last Run (0x1) python script

I have been struggling with this and I am going further and further down the rabbit hole here. I am trying to run a python script out of a .bat file contents being: @echo off "python path\python....
0
votes
0answers
66 views

uWSGI cannot find “application” using Flask and Virtualenv

This is the error im getting using uwsgi on my webserver *** Operational MODE: single process *** ModuleNotFoundError: No module named 'app' unable to load app 0 (mountpoint='') (callable not found or ...
-2
votes
1answer
98 views

Couldn't work ccxt package [closed]

I'm a beginner. I have a problem in google Cloud Functions service. I want to use ccxt python package but from this week it couldn't deploy my python program. In cloud Functions log page Traceback (...
1
vote
0answers
867 views

Python3.8 pip ProxyError: Cannot connect to proxy on CentOS Linux release 7.9.2009

Im having trouble installing libraries using pip in my freshly installed CentOS 7 (7.9.2009) server. I installed python 3.8.3 and upgrade the pip right away to the latest version 21.0.1. Already ...
0
votes
1answer
50 views

I am getting python errors for regular shell commands

The picture of the python error: This is just normal shell, i don't know why i am getting python errors and not command not found errors.
0
votes
2answers
99 views

How can a docker container image be constructed “FROM scratch” that only has a python program and the basic python interpreter?

No Alpine, Ubuntu, Debian, CentOS, yum, apt, apk, pip, etc. - just the bare minimum necessary to run a python program. Of course, it will probably have requirements that need to be installed also, ...
1
vote
1answer
33 views

What is the best way to keep files in sync between an EC2 instance and a local Win Machine?

Premise: I'm a complete newb. So any gentle hints are much appreciated :) So, I spun up an EC2 instance and dumped my scraper I had built in Python. I've set up cronjobs to run my scraper at scheduled ...
0
votes
0answers
16 views

scp.SCPException: ser **** (100) may not copy files

I'm not sure why I see this error message at times and other times the scp succeeds without any issues. How do I fix it? Traceback (most recent call last): File "/usr/lib/python3.6/threading.py&...
1
vote
1answer
43 views

SAP HANA on Ubuntu - xs login results in python error

In installed SAP Hana according to How to install SAP Hana Express Edition 2.0 on Ubuntu 18.04 (Bionic Beaver) (issues have been commented in the blog above) Following this I wanted to explore the XSA ...
1
vote
0answers
17 views

why are there so few simultaneous requests in Locust?

Why are there 2 requests on average if I spawn 100 users simultaneously? Shouldn't there be 100 simultaneous requests at the beginning? What may be the reason that does not happen? I have set up a ...
1
vote
1answer
2k views

CryptographyDeprecationWarning: Python 3.5 support will be dropped in the next release of cryptography. Please upgrade your Python

I'm trying to use docker-compose (which was installed via pip3), yet running into following warning everytime I do anything: # docker-compose version /usr/local/lib/python3.5/dist-packages/paramiko/...
0
votes
0answers
12 views

I not see changes on my Django project

I have the server Nginx+uwsgi. Uwsgi working as emperor. After I change py file in vassal Django project. In production nothing changed. I try to touch vassal ini file in turned on master, but aslo ...
0
votes
1answer
29 views

automated creation of a configuration file with ansible (or something else)

I have to create a pipeline in order to automate creation-deployment and update configuration file for network devices (switch-routers-firewall, mostly cisco). There's many ways i think to do the job ...
0
votes
1answer
48 views

Fail2ban does not perform regex on odoo log

I have installed fail2ban with odoo 13. Below are my configuration and sample output, but I cant seem to figure out why it does not filter. user@tempdev:/etc/fail2ban# fail2ban-regex -v /var/log/odoo/...
0
votes
1answer
402 views

Python throws KeyError when exporting environment variables

I have a weird case where i have a secret.env file where i set all my environment variables as such: secret.env export TWITTER_CONSUMER_KEY="something" export TWITTER_CONSUMER_SECRET="...
0
votes
1answer
20 views

Installing the Scripting Extension Python - SNAPSHOT JARs

I am trying to install the Geoserver Scripting Extension - Python (description). After downloading geoserver-2.17-SNAPSHOT-python-plugin (my Geoserver is 2.17.0) I followed the instructions: Extract ...
0
votes
1answer
61 views

Systemd python script won't log (buffer cause)?

Although the problem exposed here seems very similar, none of the solutions provided work. Context : Raspberry Pi Zero W, Raspbian Lite (2020-08-20) I want to register a python3 script as a service, ...
1
vote
2answers
241 views

couldn't upgrade to fedora due to error “nothing provides python3.8dist(python-magic)”

I'm using fedora 32. I did sudo dnf update -y I got below error - $ sudo dnf update -y Last metadata expiration check: 1:24:24 ago on Mon 30 Nov 2020 04:42:35 PM EST. Dependencies resolved. Problem: ...
0
votes
1answer
27 views

How do i add nodejs runtime layer layer to my Python Lambda on AWS?

wscat test In my Python lambda I want to use wscat which requires node: $ /opt/wscat-layer/bin/wscat /usr/bin/env: node: No such file or directory Question: How do I add nodejs runtime to my Python ...

1
2 3 4 5
32