-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
set --enable-loadable-sqlite-extensions in configure? #488
Comments
Hi! To pre-empt what I imagine will be Kenneth's question... what's the use case for using sqlite extensions (or sqlite at all) on Heroku dynos? (Since the filesystem is ephemeral) |
Sqlite: Sqlite-extension: |
sqlite is very useful to have, as it’s a very fast database that can be used despite our ephemeral filesystem — it just can’t be used persistiently. In addition to that, some tools/libraries, e.g. iPython, import sqlite, expecting it to be available as part of the stdlib, and will not function if it is not compiled at build time. I don’t forsee changing our level of support here, though. |
I just ran into the missing support for loadable extensions myself (I have a read-only sqlite DB and an extension for PCRE support). I understand that this is not a common use case, but the change is trivial and I can't really think of any downsides (there's no extra dependency or anything). Would you be willing to reconsider? My workaround for now is using a # rebuild python if it's missing loadable sqlite extensions
if ! python3 -msysconfig | grep enable-loadable-sqlite-extensions \
> /dev/null; then
PYTHON_VERSION="$(< runtime.txt)"
export WORKSPACE_DIR="$(cd "$BIN_DIR"/.. || exit; pwd)/builds"
rm -f .heroku/python/bin/python # prevent failing ln after build
sed -i 's!figure --pre!figure --enable-loadable-sqlite-extensions --pre!' \
"$WORKSPACE_DIR"/runtimes/python3
"$WORKSPACE_DIR/runtimes/$PYTHON_VERSION" /app/.heroku/python/
fi |
@obfusk Hi! I've reopened this issue to remind me to take a look when I get a chance to triage the issues in this repo (have been catching up with urgent fixes/tech debt first; hope to get to triage soon). |
The official Python docker images use |
So do Debian & Ubuntu and AFAIK most other Linux distros. Also Termux. |
Tracking internally at W-8060029. |
@obfusk hello I have same problem with you but what I want to add is can you tell me how and where to add that thanks edit: Ok seems I just need to add |
Release announcement: https://www.python.org/downloads/release/python-3100/ https://blog.python.org/2021/10/python-3100-is-available.html More detailsed "What's new": https://docs.python.org/3.10/whatsnew/3.10.html For this release, a new version of the buildpack's Python build script has been added, which includes some long-overdue improvements: - enables PGO (`--enable-optimizations`) - enables loadable SQLite extensions (`--enable-loadable-sqlite-extensions`) - enables strict configure option checking (`--enable-option-checking=fatal`) - the make invocation now uses concurrency (!!) - the test module cleanup step now also removes the `idle_test` directory These bring our Python builds closer in-line with those used elsewhere, for example: https://github.com/docker-library/python/blob/d65295b73bc2c711de96caeba17501d1a81b6a5c/3.9/buster/Dockerfile#L43-L45 For docs on the configure options, see: https://docs.python.org/3.10/using/configure.html Fixes #488. GUS-W-8060029. GUS-W-9093281.
Release announcement: https://www.python.org/downloads/release/python-3100/ https://blog.python.org/2021/10/python-3100-is-available.html More detailsed "What's new": https://docs.python.org/3.10/whatsnew/3.10.html For this release, a new version of the buildpack's Python build script has been added, which includes some long-overdue improvements: - enables PGO (`--enable-optimizations`) - enables loadable SQLite extensions (`--enable-loadable-sqlite-extensions`) - enables strict configure option checking (`--enable-option-checking=fatal`) - the make invocation now uses concurrency (!!) - the test module cleanup step now also removes the `idle_test` directory These bring our Python builds closer in-line with those used elsewhere, for example: https://github.com/docker-library/python/blob/d65295b73bc2c711de96caeba17501d1a81b6a5c/3.9/buster/Dockerfile#L43-L45 For docs on the configure options, see: https://docs.python.org/3.10/using/configure.html Fixes #488. GUS-W-8060029. GUS-W-9093281.
It'll be nice if heroku could enable sqlite extension by default
The text was updated successfully, but these errors were encountered: