Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 5372

Python • Re: ValueError: invalid literal for int() with base 10:

$
0
0
Everything was fine here at midnight on the 3rd of January.

You could try adding some code which logs what your program is doing. Then log the thing that is about to get processed by the line that gives you the error.

Probably you are getting data from somewhere else and expecting it to look like a number, but instead you're getting a string. Maybe you're getting an error message sent to you, which can not be converted to a number.

Log everything. Then, next year, you'll be able to see what caused the problem.

Statistics: Posted by ame — Fri Jan 05, 2024 1:06 am



Viewing all articles
Browse latest Browse all 5372

Trending Articles