git: e46287dee8e1 - main - databases/py-surrealdb: New port: SurrealDB python client
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 09 Nov 2026 16:49:19 UTC
The branch main has been updated by yuri:
URL: https://cgit.FreeBSD.org/ports/commit/?id=e46287dee8e17bddcbbdc8859f884289ad3bdfcc
commit e46287dee8e17bddcbbdc8859f884289ad3bdfcc
Author: Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2026-11-09 16:44:14 +0000
Commit: Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2026-11-09 16:47:24 +0000
databases/py-surrealdb: New port: SurrealDB python client
Approved by: no need for approval according to bapt@
---
databases/Makefile | 1 +
databases/py-surrealdb/Makefile | 40 ++++++++++++++++++++++++++++++++++++++++
databases/py-surrealdb/distinfo | 3 +++
databases/py-surrealdb/pkg-descr | 5 +++++
4 files changed, 49 insertions(+)
diff --git a/databases/Makefile b/databases/Makefile
index 23fb5aabfd93..1c9128233e37 100644
--- a/databases/Makefile
+++ b/databases/Makefile
@@ -928,6 +928,7 @@
SUBDIR += py-sqlparse
SUBDIR += py-sqlrelay
SUBDIR += py-squall-sql
+ SUBDIR += py-surrealdb
SUBDIR += py-tableschema
SUBDIR += py-tarantool
SUBDIR += py-tiledb
diff --git a/databases/py-surrealdb/Makefile b/databases/py-surrealdb/Makefile
new file mode 100644
index 000000000000..ef7d039b1e44
--- /dev/null
+++ b/databases/py-surrealdb/Makefile
@@ -0,0 +1,40 @@
+PORTNAME= surrealdb
+PORTVERSION= 3.0.0
+CATEGORIES= databases python
+MASTER_SITES= PYPI
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= yuri@FreeBSD.org
+COMMENT= SurrealDB python client
+WWW= https://github.com/surrealdb/surrealdb.py \
+ https://surrealdb.com/docs/sdk/python
+
+LICENSE= APACHE20
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=0:devel/py-hatchling@${PY_FLAVOR}
+RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}aiohttp>=3.14.0:www/py-aiohttp@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pydantic-core>=2.10.0:devel/py-pydantic-core@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}requests>=2.25.0:www/py-requests@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}typing-extensions>=4.6.0:devel/py-typing-extensions@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}websockets>=15.0:devel/py-websockets@${PY_FLAVOR}
+TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hypothesis>0:devel/py-hypothesis@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pytest-asyncio>0:devel/py-pytest-asyncio@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}pyyaml>0:devel/py-pyyaml@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}responses>0:devel/py-responses@${PY_FLAVOR}
+
+USES= python
+USE_PYTHON= autoplist concurrent pep517 pytest
+
+NO_ARCH= yes
+
+TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
+TEST_ARGS= --disable-plugin-autoload \
+ -p pytest_asyncio.plugin \
+ --ignore=tests/unit_tests/conformance \
+ --ignore=tests/unit_tests/connections/embedded \
+ --ignore=tests/unit_tests/test_examples_use_the_real_api.py
+
+# tests as of 3.0.0: 1381 passed, 1165 skipped, 2 warnings in 21.54s
+
+.include <bsd.port.mk>
diff --git a/databases/py-surrealdb/distinfo b/databases/py-surrealdb/distinfo
new file mode 100644
index 000000000000..9ef68030b5b6
--- /dev/null
+++ b/databases/py-surrealdb/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1794241984
+SHA256 (surrealdb-3.0.0.tar.gz) = 1b885704ac871de5d5eb8fac476a746b26fe2f2cd3e833c4c91abd11d2bdb615
+SIZE (surrealdb-3.0.0.tar.gz) = 604948
diff --git a/databases/py-surrealdb/pkg-descr b/databases/py-surrealdb/pkg-descr
new file mode 100644
index 000000000000..b69a00cf6406
--- /dev/null
+++ b/databases/py-surrealdb/pkg-descr
@@ -0,0 +1,5 @@
+The official Python SDK for SurrealDB.
+
+It provides both asyncio and blocking clients for connecting to SurrealDB
+over HTTP or WebSocket, along with the data types and CBOR encoding used by
+the database.