In my local machine I have created a script in python that retrieves data from an Oracle database. The connection to the DB is done using cx_Oracle: When using SQL developer the connection is established using custom JDBC. Replicate procedure on a Linux server. I have created a python virtual environment with cx-Oracle pip installed in it. I have Oracle
Tag: linux
How do I pause other processes when user input / confirmation is required Subprocess Python
If I have a script (process run.py) that will run 3 subprocesses A.py, B.py, C.py (3 scripts called at same time through process run.py). The operation is fine. However say in b.py i have a line such as (pref) How can i get subprocess of A.py and c.py to wait/pause for 5seconds, in order for user to enter y or
Syntax error calling Python from C with fork-execv
I want to call a Python script as a child process from a C program using fork and execv. I have tested it calling bin/ls and it works: So I changed the C code to call the Create_Buffer() function in this Python file: The Python script has two functions; I want to call Create_Buffer(), so I changed my C file
Getting an error when trying to download a Python package on Linux
I want to use the ‘bleak’ package on a raspberry bi to connect to Bluetooth Low Energy peripherals. When I use the command pip install bleak i get the error : Could not find a version that satisfies the requirement dbus-next; platform_system == “Linux” (from bleak) (from versions: ) No matching distribution found for dbus-next; platform_system ++ “Linux” (from bleak)
Mouse, and keyboard python modules conflicting?
I am writing a test program which contains the mouse, and keyboard modules together, but they conflict when I run the program. If applicable, I run Linux Mint 20.04 (Uma). Here is my code: If I run this program normally, such as /bin/python3 /home/bhrz/Scripts/Python/Mouse/main.py in my terminal, it outputs: When I attempt to solve that error by entering this, sudo
Ansible get search domain from DNS in Ansible facts [closed]
Closed. This question needs debugging details. It is not currently accepting answers. Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question. Closed 1 year ago. Improve this question How can I use the search domain in a variable? When I use
Remove specific data from json file in linux
I have a json file with set of data with repeating fields. I need to remove an entry with specific data of a field. Json file: The json file goes on and but this is an example of the whole json file. I need to remove an entry of targets with its labels given a data of the target’s IP.
python packages not being installed on the virtual environment using ubuntu
I have a requirements.txt file which holds all information of my python packages I need for my Flask application. Here is what I did: python3 -m venv venv source venv/bin/activate sudo pip install -r requirements.txt When I tried to check if the packages were installed on the virtual environment using pip list, I do not see the packages. Can someone
Getting rid of the apostrophe in subprocess.Popen to move files
My script generates multiple files that contain random names based on the info it extracts. I created this test to try and move all new files created while running into a new directory named after the file being ran. When I use os.popen(“mv ” + moveFiles +’ ‘ + filename + “_dir”) it works just fine, but os.popen is considered
PIP Install file not found on Linux Servers [closed]
Closed. This question needs debugging details. It is not currently accepting answers. Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question. Closed 1 year ago. Improve this question I’m trying to install PIP on Ubuntu 20.04.02 but apparently the command sudo