Skip to content

Conversation

@jdstrand
Copy link
Contributor

@jdstrand jdstrand commented Dec 9, 2025

@jdstrand jdstrand added the v3 label Dec 9, 2025
@jdstrand
Copy link
Contributor Author

jdstrand commented Dec 9, 2025

Testing:

$ for i in *.gz ; do mkdir $(basename -s .tar.gz $i) ; tar -zxf $i -C $(basename -s .tar.gz $i) ; done
$ ls -l
total 591488
drwxrwxr-x 3 jamie jamie      4096 Dec  9 14:49 influxdb3-core_aarch64-apple-darwin
-rw-rw-r-- 1 jamie jamie  97755586 Dec  9 09:31 influxdb3-core_aarch64-apple-darwin.tar.gz
drwxrwxr-x 3 jamie jamie      4096 Dec  9 14:49 influxdb3-core_aarch64-unknown-linux-gnu
-rw-rw-r-- 1 jamie jamie 155085560 Dec  9 09:31 influxdb3-core_aarch64-unknown-linux-gnu.tar.gz
drwxrwxr-x 3 jamie jamie      4096 Dec  9 14:49 influxdb3-core_x86_64-pc-windows-gnu
-rw-rw-r-- 1 jamie jamie 173249309 Dec  9 09:31 influxdb3-core_x86_64-pc-windows-gnu.tar.gz
drwxrwxr-x 3 jamie jamie      4096 Dec  9 14:49 influxdb3-core_x86_64-unknown-linux-gnu
-rw-rw-r-- 1 jamie jamie 179554987 Dec  9 09:32 influxdb3-core_x86_64-unknown-linux-gnu.tar.gz
$ grep python_version ./*/python/licenses/PYTHON.json
./influxdb3-core_aarch64-apple-darwin/python/licenses/PYTHON.json:    "python_version": "3.13.11",
./influxdb3-core_aarch64-unknown-linux-gnu/python/licenses/PYTHON.json:    "python_version": "3.13.11",
./influxdb3-core_x86_64-pc-windows-gnu/python/licenses/PYTHON.json:    "python_version": "3.13.11",
./influxdb3-core_x86_64-unknown-linux-gnu/python/licenses/PYTHON.json:    "python_version": "3.13.11",

# Linux debug builds aren't patchelf'd
$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 --version
./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3: error while loading shared libraries: libpython3.13.so.1.0: cannot open shared object file: No such file or directory

# fix that
$ patchelf --set-rpath '$ORIGIN/python/lib' ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3
$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 --version
influxdb3 3.8.0-nightly, revision 8b9078fa613740a2ecfce24ad7cc3ced8814cd05

# start the server in one terminal
$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 serve --object-store memory --node-id n1 --without-auth --plugin-dir /tmp/plugins
...
2025-12-09T20:54:47.830586Z  INFO influxdb3_server: startup time: 175ms address=0.0.0.0:8181

# in another terminal
$ cat /tmp/plugins/testme.py 
import importlib.util
import requests
import sys
def process_scheduled_call(influxdb3_local, call_time, args=None):
    influxdb3_local.info("sys.prefix = %s" % sys.prefix)
    influxdb3_local.info("sys.path = %s" % sys.path)
    spec = importlib.util.find_spec("requests")
    if spec is not None:
        influxdb3_local.info("'requests' location = %s" % spec.origin)
    else:
        influxdb3_local.info("'requests' location = not found")

    influxdb3_local.info("requests = %s" % requests.__version__)

$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 install package requests
$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 create database mydb01
Database "mydb01" created successfully
$ ./influxdb3-core_x86_64-unknown-linux-gnu/influxdb3 test schedule_plugin -d mydb01 testme.py
{
  "trigger_time": "2025-12-09T20:58:18Z",
  "log_lines": [
    "INFO: sys.prefix = /tmp/plugins/.venv",
    "INFO: sys.path = ['/tmp/core/influxdb3-core_x86_64-unknown-linux-gnu/python/lib/python313.zip', '/tmp/core/influxdb3-core_x86_64-unknown-linux-gnu/python/lib/python3.13', '/tmp/core/influxdb3-core_x86_64-unknown-linux-gnu/python/lib/python3.13/lib-dynload', '/tmp/plugins/.venv/lib/python3.13/site-packages']",
    "INFO: 'requests' location = /tmp/plugins/.venv/lib/python3.13/site-packages/requests/__init__.py",
    "INFO: requests = 2.32.5"
  ],
  "database_writes": {},
  "errors": []
}

@jdstrand jdstrand merged commit 75feb9c into main Dec 9, 2025
12 checks passed
@jdstrand jdstrand deleted the jdstrand/update-py-3.13.11 branch December 9, 2025 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants