All Questions
Tagged with python-shell or python
2,211,556 questions
0
votes
0
answers
3
views
Run a dataframe of URLs through a function - Python
I am trying to use a dataframe that contains a bunch of URLs and run each individual URL through a function. Note: the function works perfectly if called with a single URL i.e. myfunction(https://www....
0
votes
0
answers
12
views
Why am I getting errors with discord.ActionRow in discord.py?
I'm trying to create a game using buttons in Discord with discord.py, and I'm using discord.ActionRow, but it's giving me errors. Here's the function for context:
async def create_game_board(self, ...
0
votes
0
answers
9
views
Getting confidence scores for fields extracted from image-to-text LLM inference
I am extracting details from cheques using fine-tuned Qwen 2.5 VL 7B model. I want to have confidence scores for the fields as in azure document intelligence.
A few ways I think I can do it is using ...
0
votes
0
answers
29
views
How do I get the length of a WriteableBuffer?
Previous question: How do I add a type hint for a WriteableBuffer parameter?
I'm trying to implement the readinto() method of a RawIOBase subclass with correct type hints.
The version I have so far ...
-3
votes
0
answers
36
views
how i can fix this security problem on mariadb? [closed]
I'm making an auth system who requests for the user and the password then sends a requests to the database on mariadb to validate the request. The problem is that I need to make a user for the ...
0
votes
0
answers
18
views
Selenium Firefox web scraping issues on Linux [closed]
I will write a Python script for web scraping on Linux using Firefox, but I'm facing some issues. Can anyone help?
-3
votes
0
answers
38
views
Selecting and Managing Addresses in a Criminal Recognition and Tracking Desktop App [closed]
Description:
I'm developing a desktop application for criminal recognition and tracking using [specify language/framework, e.g., Python with Tkinter, C# with .NET, etc.]. The app needs to handle ...
-3
votes
0
answers
43
views
Menu driven database management system
I am developing a menu-based system free of charge to computerize some manual tasks in order to help a friend better manage a small business.
I am new to Python and trying to use a top-down, menu-...
0
votes
1
answer
44
views
How do I add a type hint for a WriteableBuffer parameter?
I'm trying to add a parameter type to the readinto() method declared in a custom class that derives from RawIOBase, like this:
from io import RawIOBase
class Reader(RawIOBase):
def readinto(self, ...
0
votes
0
answers
30
views
Why does my first test run timeout (but second run does not) when running multiple Python scripts with ThreadPoolExecutor or ProcessPoolExecutor?
I am working on an automated grading tool for student programming submissions.
The process is:
Students submit their code (Python projects).
I clean and organise the submissions.
I set up a separate ...
0
votes
3
answers
34
views
How can I stop a matplotlib table overlapping a graph?
The MWE below produces a plot like this:
The row labels, X, Y, Z, overlap the right hand side of the bar chart in an ugly fashion. I'd like them moved further to the right, leaving a small margin ...
0
votes
1
answer
26
views
Using classmethods, class objects and generics together with mypy
I use the following code to create subclasses of class G and pass them the type of model they should produce.
from typing import TypeVar, Type
class A:
@classmethod
def model_validate(cls):
...
0
votes
0
answers
17
views
Pylance & Pylint report “could not be resolved” / “no-member” for a valid PyPI package in VSCode virtual environment
What configuration changes are needed in VSCode (or in my project layout) to make Pylance and Pylint recognize the installed cowsay package and its members? Is there a best practice for structuring ...
-7
votes
0
answers
35
views
How to define and call a simple function in Python? [closed]
I’m a beginner in Python and trying to learn how to create and use functions.
• How do I pass parameters to a function?
• How can a function return a value instead of just printing?
-2
votes
0
answers
18
views
PDF to Word with structure preservation (similar function to tools like pdf2word.com) [closed]
So, I am looking for python code help to convert pdf to word doc perfectly like this pdf2word.com does it.
I have used pdf2docx library which is most common but the structure preservation is not good ...