I had this issue when trying to run lm-eval-harness. I updated sqlite to the latest version 3.45.3 and reinstalled Python 3.12 which got upgraded from 3.12.3 to 3.12.9. Then I reinstalled lm-eval-harness.
lm-eval-harness
sqlite
3.45.3
3.12
3.12.3
3.12.9
This made it work.