Skip to main content
Filter by
Sorted by
Tagged with
Advice
0 votes
6 replies
103 views

I am an amateur playing around with making simple games using Python and the Windows console through sys.stdout.write(). I am aware that this method of doing 'graphics' with printing ascii characters ...
RyanNewtonIV's user avatar
4 votes
1 answer
128 views

I am developing an app to select and play a mp3 clip from a list. It will be run on a Pi4 with 7” touch display and piAMP+ hat. The GUI is in tkinter with pygame for the sound plus a pair of GPIO pins ...
Cheesehead's user avatar
-1 votes
1 answer
89 views

I am trying to start a Dialog including QListWidget. In this list every time a status is changed, the list should get a new line. At the end, if the backup process has finished, the dialog should ...
Stefan Bongers's user avatar
0 votes
0 answers
50 views

I am running free-threaded python3.13t with PYTHON_GIL=0 on MacOS Sequoia 15.7. I create threads like this: thread = threading.Thread(target=lambda: time.sleep(10), name="test-thread") ...
Boris Burkov's user avatar
  • 14.7k
-1 votes
2 answers
133 views

We run a bunch of wireless controllers (mc's) and I want to use the controller API to transfer firmware via TFTP to each controller in preparation for an upgrade (the API call needs to be run on each ...
Guy Goodrick's user avatar
0 votes
1 answer
44 views

I am running a gunicorn server with 1 eventlet worker through which I communicate with the FE via websockets. However, I also need to listen to an external pod running some code that will emit a redis ...
Aitor Gastaminza Unanue's user avatar
-1 votes
3 answers
80 views

I am running a script that listens for webhook on my local machine using the following pattern : from flask import Flask, request, abort app = Flask(__name__) @app.route("/", methods=["...
Sahasi's user avatar
  • 3
8 votes
2 answers
547 views

I'm working on an asynchronous Python application (using FastAPI/Starlette/asyncio) that needs to offload synchronous, CPU-bound tasks to a thread pool (ThreadPoolExecutor) to avoid blocking the event ...
Hemanth Hema Surya's user avatar
0 votes
3 answers
92 views

Yet another question about tkinter terminating... Here is a minimal code : import threading,tkinter,random class MiniTk : done = lambda self : self._quit.is_set() spot = lambda self,x,y : ...
Captain'Flam's user avatar
0 votes
1 answer
82 views

When performing OCR on user-selected regions using PaddleOCR, certain regions fail to be detected. The issue occurs in a Streamlit-based application with the following implementation characteristics: ...
Big-Yellow-J's user avatar
0 votes
0 answers
55 views

I have a simple Python Win32 program that works well when run under pythonw from a command prompt. When I run it under python, it keeps running in the foreground of the command prompt and can e.g. ...
SRobertJames's user avatar
  • 9,367
0 votes
0 answers
53 views

I have a flask application that I run with Gunicorn. The application itself would ideally be run with multiple workers. I also have some data I need to consume from Kafka, but that should only be one ...
Vincent Guttmann's user avatar
0 votes
0 answers
21 views

I've tried emptying the queue every time. I've tried self.engine.stop. It either doesn't affect anything or it will work and successfully interrupt the previous speech one, twice or maybe even thrice ...
DRags's user avatar
  • 56
-1 votes
1 answer
66 views

i have a python application, that contains functions to be called by interval. def call_repeatedly(interval, func, *args, **kwargs): stopped = threading.Event() lock = threading.Lock() # Lock ...
Pythonaire's user avatar
0 votes
0 answers
413 views

I am trying to read data from a Siemens S7-1500 PLC in an asynchronous way using Python and the snap7 library. My goal is to read multiple tags concurrently. However, I am encountering the error b'CLI ...
debabrata-aic's user avatar
0 votes
1 answer
85 views

I would like to implement changing cursor in PyQT(PySide6) application. Since didn't find animated gif support for QCursor -> decided to create my own manual animation. So far: When change cursor ...
DDV's user avatar
  • 13
0 votes
1 answer
118 views

Initializing hugging face transformer causes loops to restart. I have created simple loop which reads text and replies but the loop is restarting new thread when initalizing chatbot pipeline. Minimum ...
Shahir Ansari's user avatar
0 votes
0 answers
72 views

I'm helping develop a Python application which collects data from several sensors and manages a server to send those data to a web application (React) to display. The application is supposed to work ...
mysh's user avatar
  • 118
2 votes
1 answer
130 views

I am trying to create small examples using Locks to demonstrate the issues that Locks will resolve in a multi-threaded environment. The example I created is the following, import threading # Shared ...
memelord23's user avatar
0 votes
0 answers
29 views

I am trying to implement the shared memory database. The objective is to allow non-blocking reading access to the database for the IPC among threading. The setting is following def __init__(self): ...
kusocodeing's user avatar
0 votes
2 answers
489 views

I want to use ThreadPoolExecutor to parallelize some (legacy) code with database access. I would like to avoid creating a new database connection for each thread, so I use threading.local() to keep a ...
Eugene Yarmash's user avatar
1 vote
2 answers
43 views

I'm doing concurrency using Multiprocessing() and Threading(). The idea is to spawn multiple threads from multiple process. The threads needs to access global variable that use Value() so that ...
Guild's user avatar
  • 11
0 votes
3 answers
50 views

I have some program that communicates with the user. The program should terminate when the user has entered a sample text. import time import threading def printer(): while True: print(&...
Stupid Hub's user avatar
1 vote
1 answer
181 views

Is a lock necessary in a situation where thread 1 checks if a bool has flipped from False to True periodically within a loop, the bool being updated in thread 2? As I understand a bool is atomic in ...
Hugo Schongin's user avatar
-1 votes
1 answer
39 views

I'm developing a two-player multiplayer game with pygame. Here is the server code and client code: <Server Code> import json import pygame # Main module for the game import pyautogui # For ...
이관우's user avatar

1
2 3 4 5
83