Questions tagged [python3]

Python is an interpreted, general, high-level programming language. Programming questions are off topic. Questions about the use of Python should be asked at Stack Overflow (http://www.stackoverflow.com) instead.

Filter by
Sorted by
Tagged with
-1 votes
1 answer
28 views

Add python.exe to the path on Windows

My Windows 10 has Python 2.7 installed. I don't have admin privileges' and can't un-install it. I installed Python 3 now. Hence I have 2 versions ... but I want that default be Python 3. I created ...
susik's user avatar
  • 643
0 votes
1 answer
96 views

Update Python3 to new installed version on Ubuntu 18.04

Tried searching with several strategies but am not finding an effective answer. I just installed Python-3.11.5 to a directory under my "home" directory. When I am in Terminal and type me@...
BondedDust's user avatar
0 votes
0 answers
39 views

How to make Anaconda pip as the default pip

My Python 3 pip is messing up. Apparently I have a non-conda pip as the default pip but conda python is my default python (as below), which is messing up with package installations: >which -a pip /...
Tina J's user avatar
  • 579
0 votes
1 answer
189 views

Error while running python3-fail2ban with "PY_SSIZE_T_CLEAN macro must be defined for '#' formats"

I'm trying to run the python3-fail2ban component built by yocto, but I'm encountering an error related to the PY_SSIZE_T_CLEAN macro. The error message is PY_SSIZE_T_CLEAN macro must be defined for '#'...
zaheerk's user avatar
0 votes
0 answers
22 views

GIT CI/CD failure with Python3.11

I'm running into an interesting situation. I have a machine that I'm doing some development on in RUST primarily, but there are a few scripts that we are doing in Python. For different purposes, but ...
Michael's user avatar
  • 153
0 votes
1 answer
34 views

Regex: Select string without Search/Replace

I have many lines like this: <i class="fa fa-angle-right font-14 color-blue mr-1"></i> Books To Read <span>30</span> <i class="fa fa-angle-right font-14 color-...
Just Me's user avatar
  • 816
0 votes
1 answer
343 views

How to install python packages in an unstable connection

I've been trying to install tensorflow but without success. I suspect the reason is unstable internet connection because I was able to successfully install a smaller package (openCV) minutes before ...
Mehdi Charife's user avatar
0 votes
0 answers
26 views

Task Scheduler running a Program incorrectly

I have created a python exe that copies data from a NAS to a external HDD. This is on a Windows sever 2012 and the NAS and External is accessible to use. Also using the user account with full admin ...
JohanvW's user avatar
2 votes
1 answer
342 views

Ansible - How to create dynamic inventory that fetches hosts from microsoft AD

I am using Ubuntu as a control-node, and would like to get the hosts from my domain controller (windows server 2022), the LDAP-Inventory Guide & microsoft.ad.ldap inventory – Inventory plugin for ...
AMM's user avatar
  • 23
1 vote
1 answer
775 views

Can't install wxPython by using pip on a Python 3.10.11 installation

I've recently installed Python 3.10.11 on openSuSE 15.4 from source as the Python version, which comes with SuSE, had proved too old (3.6). Now I need to add several modules, of which one is wxPython&...
Neppomuk's user avatar
  • 229
1 vote
1 answer
734 views

How to overcome a missing msvcrt module when installing Python 3 from source on OpenSuSE Linux?

In order to test a fresh version of a Python app, I need to install the last stable version of Python on my OpenSuSE 15.4 machine /* which by default comes with Python 3.6 */. So I downloaded Python 3....
Neppomuk's user avatar
  • 229
0 votes
1 answer
18 views

Running paparzzi UAV in git bash

I got this error when trying to running paparazzi UAV in git bash. can anyone help me solve this problem ? /usr/bin/env: ‘/usr/bin/python3’: No such file or directory
Amrhus's user avatar
  • 1
-2 votes
1 answer
211 views

CMD/Python: Guess your .docx or .txt file's encoding

Ok, I want to find out, what kind of files I have, for encoding. I tried to read the file with encoding='UTF-8' and it failed, which indicates that the document is not utf8-encoded. Of course, I could ...
Just Me's user avatar
  • 816
0 votes
0 answers
9 views

Random stopping of the ClamD daemon

I am running ClamAV on a system that is offline(or for practical purposes blocks the URLs from where ClamAV downloads its AV definitions which is similar to it being offline). I replaced the ...
Apurva Kunkulol's user avatar
0 votes
0 answers
32 views

How to find RDFLib installation on Windows and add it to the path (Environment Variables)

I am using Anaconda on windows. I have installed RDFLib through Jupyter Notebooks. My programs using RDFLib work without problems. I downloaded my program on Jupyter Notebook as myfile.py file, and I ...
Karl 17302's user avatar
0 votes
0 answers
2k views

WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available. [ Raspberry Pi Python 3.10.9 ]

I am using a raspberry pi and trying to update from Python3.9 to Python3.10.9 I use the following commands: sudo apt install build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev ...
frend123123's user avatar
1 vote
1 answer
522 views

Why doesn't the winget package of python include python3.exe?

The community-accepted solution for including a shebang line for Python seems to be to use #!/usr/bin/env python3. However, when I install Python 3 using the winget package (i.e. winget install --id ...
Casey Kuball's user avatar
1 vote
2 answers
7k views

Why am I getting "command not found" error on my VS?

/bin/sh: python3.11.1: command not found [Done] exited with code=127 in 0.003 seconds I am using VS for macOS.
Aydan Baghirzade's user avatar
1 vote
1 answer
1k views

How to delete Python on mac completely?

I want to download only the latest version of Python and get rid of the old ones. I already deleted all the old ones I downloaded before. But when I check for Python versions in my terminal or import ...
Aydan Baghirzade's user avatar
0 votes
0 answers
293 views

Ubuntu 18.04.6 LTS on Azure VM can't run apt upgrade: ModuleNotFoundError: No module named 'apt_pkg'

I got this error message when I try to update the software installed with APT: $ sudo apt update && sudo apt upgrade Hit:1 http://azure.archive.ubuntu.com/ubuntu bionic InRelease Get:2 http://...
FeDos's user avatar
  • 81
1 vote
1 answer
5k views

Installing Python 3.10+ on WSL2 Debian Distro

I'm fairly new to Linux distros. I have Debian downloaded and running in my Windows 10 WSL2 environment. I want to install a specific version of Python - 3.10 or latest 3.11 on it. How can I do that?...
Andez's user avatar
  • 121
1 vote
0 answers
81 views

Sublime Text 4 sql highlight inside a string

Currently, if I have sql commands inside a python string, Sublime Text highlights it. However if it's an "f string", it does not recognize the sql inside. Is there any way to make it work ...
franksands's user avatar
0 votes
0 answers
720 views

How to install pip for more than one python version

I have python3.8 and I have installed python3.7 on Ubuntu 22.04. Also I have pip. When I run pip3 -V or pip -V I got pip 22.2.2 from /usr/local/lib/python3.8/dist-packages/pip (python 3.8). But when I ...
xxlali's user avatar
  • 249
0 votes
1 answer
3k views

Regex, how to get the values within { { } brackets?

I'm new to regex, just trying to get the values between curly braces { } but landed with no luck. Could anyone please help me here? This is in python BTW and i need to open a text file and split based ...
user1732131's user avatar
0 votes
1 answer
3k views

How to install the latest GDAL version on RedHat Linux 8

I am trying to install GDAL for a usage with Python 3.8. I noticed that the library is not accessible via yum directly, you need to Install it through EPEL store. dnf install -y https://dl....
kaless's user avatar
  • 11
0 votes
1 answer
489 views

uefi shell - download a file via https

I am experimenting with uefi shell from and I wish to implement the following scenario : boot into uefi shell download a a startup.nsh script from https remote resource run the downloaded startup.nsh ...
chegov's user avatar
  • 1
0 votes
0 answers
236 views

Tab-completion when running a python3 script

In Ubuntu, I'd like to be able to use tab-completion when running python. For example, if I wanted to use vim to edit a file 'myscript.py3', I'd write 'vim my' and pressing tab would complete the ...
Domantas's user avatar
0 votes
0 answers
39 views

"Edit with IDLE" is not working for .py files inside importlib package. during debugging, I cant go to source line, only for importlib package

This is the default python package named 'importlib', I am trying to access and open/edit .py files inside this package.
subtle_details's user avatar
1 vote
0 answers
195 views

FFMPEG Crop and Trim resulting in a video with stall frames in few seconds

In my video frames, two people talk side by side. I want to first get a small clip of the video and then crop them as person 1 and teacher 1. I used below code snipped to generate these small clips. ...
Daki Withanage's user avatar
3 votes
1 answer
3k views

How to remove/uninstall corrupted winget package?

When I run winget list python I get that Python.Python.3 is installed by winget; however, running python says the executable is missing. winget uninstall --id Python.Python.3 runs the uninstaller but ...
treedust's user avatar
0 votes
1 answer
2k views

Pip isn't working because some random process is running

So basically... I installed the python-certifi-win32 to solve another problem I was having, but then it was giving me a separate error. So I tried to uninstall it with pip, but I got this error: ...
Kovy Jacob's user avatar
-1 votes
4 answers
169 views

How to delete all files (or the entire content of all files) with less than 250 words with Regex?

Is it possible to delete all files (or the entire content of all files) with less than 250 words? I try this regex, but needs to be improved a little bit. Can anyone help me? Find: (?s)(.*?(\w+\s?){1,...
user avatar
2 votes
0 answers
3k views

Cannot install packages with pip - error with inconsistent version but version matches metadata

I recently have an issue trying to install anything with pip. It keeps trying older versions complaining that each one has a version mismatch, when it matches perfectly fine. This following log is ...
QuickishFM's user avatar
0 votes
2 answers
2k views

Python update broke `apt-listchanges`, completely breaking apt & dpkg

OS: Debian 11 OG Python vertion: 3.9 I updated python to 3.10 and did update-alternatives, after which on running pip i got the error: E: Sub-process /usr/bin/apt-listchanges --apt || test $? -ne 10 ...
jodobear's user avatar
0 votes
0 answers
722 views

My saved .py files can be seen in Pycharm but not in File Explorer

I already saved one file before. But when I do it now, it doesn't show in file explorer but shows in Pycharm "open" section. Any explanation and a way to fix this would be appreciated.
Lokodata's user avatar
0 votes
1 answer
55 views

How to install Python 3 in RHEL in such a way that it won't mess up the current Python 2 installation?

I have an EC2 instance which is running Python 2.x. I want to install python 3.x but I do not know if Python 2 is currently being used by anything. My questions are: How do I install Python 3 in such ...
jmrjmr's user avatar
  • 11
0 votes
1 answer
3k views

Is it possible to recover a tab in Spyder

I am new on python, and by mistake I deleted my tab that I was working on. There is a way to recover all the code I wrote? I am using Spyder as the IDE.
ROEI's user avatar
  • 1
0 votes
1 answer
896 views

Python .ipynb too large to open. Both Thonny, Jupyter Notebook shut down when trying

I am using Python 3.73 in Jupyter Notebook 4.4.0 The only This page isn't responding: Wait Ultimately, Jupyter shuts down I understand the issue is that Firefox is using too much memory. The file I ...
MSIS's user avatar
  • 115
1 vote
1 answer
451 views

Python no longer detected as a language in VS Code

I'm genuinely confused and have no idea how this happened. If I try to set the language to Python in a file, the option doesn't appear Python files have the plain text icon and there is no syntax ...
Armster's user avatar
  • 445
0 votes
1 answer
1k views

How do I installing Python 3.9.6 on Windows 10 Pro (when there is another version installed) - installer fails?

This is extremely frustrating, ideally I would like to get in touch with the Python installer team to fix the installer. I am attempting to install Python 3.9.6 on my system. I previously installed ...
user10664542's user avatar
1 vote
0 answers
5k views

RuntimeError: can't start new thread

I'm running into an issue where running multiple instances of the same Python program on my server is causing some of the jobs to throw the following error: File "/home/joe/workspace/...
Anish Sana's user avatar
1 vote
1 answer
4k views

pip3 encountering permission errors when run outside of a virtualenv

I was in the process of installing CrackMapExec (CME) on Ubuntu this afternoon, and the CME docs suggested that I install pipx and manage the installation of CME through pipx to avoid dependency ...
raintimez222's user avatar
-1 votes
1 answer
1k views

Task Scheduler does not launch chrome when Run whether user is logged on or not is selected

I have Python script for web-scraping. I am running it using papermill and then I created a batch file that I use on task scheduler to run. This workflow was running fine until my virtual machine got ...
The AG's user avatar
  • 49
0 votes
2 answers
2k views

Sub-process /usr/bin/dpkg returned an error code (1). AGAIN

I realize this seems to be a very popular question but none of the fixes worked for me. I use ubuntu 18.04 and I've been unable to apt install anything for the good part of 6 months. It says the issue ...
Savvii's user avatar
  • 101
0 votes
1 answer
4k views

Issue opening and running Python in PowerShell

I am new to python programming (already know C) and am following Zed Shaw's book Learn Python the Hard Way. For that, I need to use Python on PowerShell. When I type python in CMD, Python opens up ...
da_vinci_3864's user avatar
0 votes
0 answers
46 views

Multiple cursors at once functionality, just as in the Visual Studio Code but in every Windows application?

Was wondering if this: https://code.visualstudio.com/docs/editor/codebasics can be implemented with WinApi or by DLL calls using something such as https://www.autohotkey.com/docs/commands/DllCall.htm ...
user96769's user avatar
0 votes
1 answer
1k views

How to install python2 packages using pip while having python3?

I am on Parrot OS. I have both python 2 and Python 3 installed. ┌─[✗]─[jaysmito@parrot]─[~/] └──╼ $python --version Python 3.9.2 ┌─[jaysmito@parrot]─[~/] └──╼ $python2 --version Python 2.7.18 And pip:...
Jaysmito Mukherjee's user avatar
1 vote
1 answer
2k views

Pip3 not working at all

So a couple days ago, I had a problem where pip3 just stopped working. I was planning on upgrading my WSL2 anyway, so I just migrated to Ubuntu 20. But the same problem has occurred here too! I can't ...
randomcoder's user avatar
0 votes
1 answer
3k views

Upgrade python from 3.8.5 to 3.8.8 on Ubuntu 20.04 LTS

I'm currently trying to upgrade the python version from 3.8.5 to 3.8.8 on Ubuntu 20.04 LTS. I've been able to find information to upgrade python version from version X.Y1 to X.Y2 (minor release in ...
Alex's user avatar
  • 3
7 votes
5 answers
20k views

Ansible installed via pip3, but Ansible commands not found

I have installed Ansible via pip3, but I can't find the Ansible commands (ansible --version, ansible-playbook, etc.) Here's the listing that shows that Ansible is installed via pip3: :~# pip3 list | ...
Jinja_dude's user avatar

1
2 3 4 5
7