fix sqlite3 version detection

This commit is contained in:
Nick Sweeting 2022-06-08 18:35:31 -07:00 committed by GitHub
parent d0f129295f
commit e06717419c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -26,11 +26,12 @@ import io
import re
import sys
import json
import inspect
import getpass
import platform
import shutil
import sqlite3
import django
from sqlite3 import dbapi2 as sqlite3
from hashlib import md5
from pathlib import Path
@ -356,8 +357,8 @@ DYNAMIC_CONFIG_SCHEMA: ConfigDefaultDict = {
'DJANGO_BINARY': {'default': lambda c: django.__file__.replace('__init__.py', 'bin/django-admin.py')},
'DJANGO_VERSION': {'default': lambda c: '{}.{}.{} {} ({})'.format(*django.VERSION)},
'SQLITE_BINARY': {'default': lambda c: 'sqlite3'},
'SQLITE_VERSION': {'default': lambda c: None},
'SQLITE_BINARY': {'default': lambda c: inspect.getfile(sqlite3)},
'SQLITE_VERSION': {'default': lambda c: sqlite3.version_info},
'SQLITE_JOURNAL_MODE': {'default': lambda c: None},
'SQLITE_EXTENSIONS': {'default': lambda c: []},