Skip to main content
The 2026 Annual Developer Survey Results Site is live— view the results here!

Question list filters

Filter by
Sorted by
Tagged with
Score of 0
1 answer
12 views

The code below contains a asynchronous def that sends a request to a OAuth2 server endpoint and when the server returns 200, the client is redirected to the given redirect point called redirect_uri ...
Score of -1
0 answers
13 views

Is there an Import Hook available for hooking into after the source code has been parsed into AST but before it is compiled? I am looking for a way to keep using most of the existing Python import ...
Score of -5
0 answers
91 views

i am learning python for fun, and i am making a simple app for my friend. however i am coding on a windows and he is on mac. what is the best way to make a app for mac from windows. Ive been trying to ...
Score of -3
3 answers
102 views

I'm trying to better organize a long program I'm working on. In main.py I have this line: from core import *. There is a subfolder called core and in that folder I created a bunch of modules to ...
Score of -2
0 answers
54 views

I have a generic event base where the discriminator is a type parameter so subclasses don’t redeclare kind: from typing import Annotated, Generic, Literal, TypeVar, Union from pydantic import ...
Score of 2
1 answer
122 views

I am attempting to write a program that simulates the three-body problem using RK45 (or Runge-Kutta-Fehlberg) integration, following the outline given here PDF I am ultimately trying to use RK45 to ...
Score of -3
0 answers
159 views

QGraphicsScene subclass will not add items which reimplement QGraphicsItem.itemChange, due to QGraphicsScene subclass which inherits QGraphicsScene twice. This is not allowed in C++/Qt, its the ...
Score of -10
0 answers
136 views

Im trying to make a silly "terminal" simulator that has silly things like deleting all of your files if you try to access government secrets, but the var = input("string") command ...
Score of 2
1 answer
83 views

I have a retry loop with a per call timeout inside an overall budget: import asyncio async def fetch(budget, per_call): try: async with asyncio.timeout(budget) as outer: for i ...
Score of -5
3 answers
148 views

I have an array of potential substrings and an array of full strings. I'd like to know which elements of the potential substrings are indeed found as substrings in the full array. import numpy as np ...
Score of -3
0 answers
90 views

I'm running into an issue with hosting some code on an AWS Lambda. I'm trying to run a project on a Lambda with the following file structure: my_layer.zip/ └── python/ # This folder ...
Score of 3
1 answer
131 views

I am experementing with linux framebuffers in order to display graphics on screen without using wayland or X11. For that I made a simple script that renders a rectangle upon framebuffer: import mmap ...
Score of -2
1 answer
167 views

How do I say the following in the current version of Python? import cgi cgi_hash = {} for key in cgi.FieldStorage().keys(): cgi_hash[key] = cgi.FieldStorage()[key].value
Score of 1
1 answer
106 views

I have a function (specifically an MCP tool built with FastMCP, but this is really a Pydantic/JSON Schema question) where one parameter is required in the normal case, but must be optional when a ...
Score of -4
2 answers
172 views

I am using the `googletrans` library for the first time to run some tests. I am following the tutorial found here: https://github.com/ssut/py-googletrans The code i am using is: import asyncio from ...

15 30 50 per page
1
2 3 4 5
…
146949