close
Skip to main content
Score of 4
Accepted

Chaining programmatic expression functions failing in with_columns

If you have multiple generators in the same context, you need to unpack them yourself def my_generator(): for i in range(3): yield pl.lit(i).alias(str(i)) def my_other_generator(): ...
Score of 3
Accepted

Problems in rendering gif created with ffmpeg

The problem seems to be the GIF's color palette. The limited number of colors available in GIFs (256) means that Matplotlib/Pillow has to quantize the frames to show only those colors, which might be ...
Score of 3

Why is my coroutine wrapper working when I use it as a decorator but not when I use it as a wrapper?

We often use the word "coroutine" for two different types. Unfortunately it sometimes creates a confusion, but we must not mix those two types up. If we have e.g. async def af(), then af is ...
Score of 2
Accepted

Why is my coroutine wrapper working when I use it as a decorator but not when I use it as a wrapper?

Your exception_handler takes a function and returns a function. As a decorator that's exactly right, since do_something is a function at class definition time. But in _add_child_task, coro is already ...
Score of 2

Get Pandas to accept an arbitrary string of spaces as 'NaN'

You can use the skipinitialspace keyword argument of pd.read_csv: import io import pandas as pd DATA = """ id,value,label 1,1.23,ok 2, ,missing 3,4.56,ok """ ...
Score of 1

Updating one of Python's previous versions to its latest version for bug fixes

-V:3.13 is a runtime-selection option, so py -V:3.13 install --update launches Python 3.13 and passes install to the interpreter as a script name. That is why it tries to open D:\install.With the ...
Score of 1

How to resolve the validation error which has come while running the code involving Docling which has been configured

It seems like DoclingLoader treats convert_kwargs as keyword arguments to DocumentConverter.convert(). But by the docs, format_options belongs to the DocumentConverter constructor. Not ...
Score of 1

matplotlib savefig silently exits with code 1 after plt.plot() succeeds — no exception, no output

the problem is one of these two things: problem in environment management by confusing between numpy 1 and numpy 2 version which makes matplotlib having issue with it. you have two solutions i think: ...
Score of 1
Accepted

matplotlib savefig silently exits with code 1 after plt.plot() succeeds — no exception, no output

The issue is that you did not run conda activate bo-xgb before running ~/.conda/envs/bo-xgb/python.exe, so the environment variables like PATH was not populated by Conda, causing the Python process to ...

Only top scored, non community-wiki answers of a minimum length are eligible