Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

557
Views
Python 3.8: No module named '_sqlite3'

I have a shared hosting machine running Linux and I'm trying to get Python 3.8.3 running on it.

I have Python installed with pyenv and the correct version is globally

$ python --version
Python 3.8.3

In order to get Python working with pyenv, I have added this lines to ~/.bashrc:

export PATH="~/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"

export TMPDIR="$HOME/tmp_"

export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/shims:$PATH"

When I'm running my python script, I receive the error:

'No module named '_sqlite3'. 

Since I don't have root access, and no apt available, I have installed sqlite3 manually according to this answer.

$ wget http://www.sqlite.org/sqlite-autoconf-3070900.tar.gz
$ tar xvvf sqlite-autoconf-3070900.tar.gz
$ cd sqlite-autoconf-3070900
$ ./configure --prefix=~/tmp_
$ make
$ make install

sqlite3 is working, when I enter sqlite3 into the command line, it's working:

$ sqlite3
SQLite version 3.7.17 2013-05-20 00:56:22
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> 

I tried reinstalling Python with pyenv and linking Sqlite3 with the next statement, according to this post, but still Python response is no module '_sqlite3' found.

LDFLAGS="-L/home/wazeli1q/tmp_/tmp_/sqlite/lib" CPPFLAGS="-I/home/wazeli1q/tmp_/tmp_/sqlite/include" pyenv install -v 3.8.3

Last attempt was to install sqlite3 into the .local folder, but that did work eighter:

./configure --prefix=$HOME/.local
make && make install

What is going wrong? Just to make clear: I don't have apt and I don't have sudo rights.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!