The auto-solver crashes with a Pillow error when trying to read the captcha image downloaded from Discord.
The image download from Discord was incomplete or corrupt. Pillow's Image.open() is lazy — it only fully decodes the image when .load() or a pixel operation is called, so corrupt bytes pass the open() check and crash later inside ONNX.
In captcha_solver/solve.py, call handle.load() before np.asarray(). In cogs/captcha.py, validate the downloaded bytes with Image.open(BytesIO(img_data)).load() before writing to disk. If it raises, skip the solve.
handle = Image.open(source)
return np.asarray(handle.convert('RGB'))
handle = Image.open(source)
handle.load()
return np.asarray(handle.convert('RGB'))