ds-provider-postgresql-py-lib
A PostgreSQL provider for the DS resource plugin ecosystem.
Installation
pip install ds-provider-postgresql-py-lib
Features
- PostgreSQL linked service with connection pooling and health checks.
- PostgreSQL dataset implementation with support for:
read()create()update()upsert()delete()purge()
- DS resource typing via:
ds.resource.linked_service.postgresqlds.resource.dataset.postgresql
Usage
Public exports
from ds_provider_postgresql_py_lib import (
PostgreSQLDataset,
PostgreSQLDatasetSettings,
PostgreSQLLinkedService,
PostgreSQLLinkedServiceSettings,
__version__,
)
Minimal linked service example
import os
import uuid
from ds_provider_postgresql_py_lib import (
PostgreSQLLinkedService,
PostgreSQLLinkedServiceSettings,
)
linked_service = PostgreSQLLinkedService(
id=uuid.uuid4(),
name="postgres-linked-service",
version="1.0.0",
settings=PostgreSQLLinkedServiceSettings(
uri=os.getenv("DATABASE_URI", ""),
),
)
linked_service.connect()
ok, message = linked_service.test_connection()
print(ok, message)
Minimal dataset read example
import os
import uuid
from ds_provider_postgresql_py_lib import (
PostgreSQLDataset,
PostgreSQLDatasetSettings,
PostgreSQLLinkedService,
PostgreSQLLinkedServiceSettings,
)
from ds_provider_postgresql_py_lib.dataset.postgresql import ReadSettings
dataset = PostgreSQLDataset(
id=uuid.uuid4(),
name="postgres-dataset",
version="1.0.0",
linked_service=PostgreSQLLinkedService(
id=uuid.uuid4(),
name="postgres-linked-service",
version="1.0.0",
settings=PostgreSQLLinkedServiceSettings(
uri=os.getenv("DATABASE_URI", ""),
),
),
settings=PostgreSQLDatasetSettings(
schema="public",
table="test",
read=ReadSettings(limit=10),
),
)
dataset.linked_service.connect()
dataset.read()
print(dataset.output)
Requirements
- Python 3.11+
- See
pyproject.tomlfor the full dependency set.
Documentation
- Repository: https://github.com/grasp-labs/ds-provider-postgresql-py-lib
- Docs: https://grasp-labs.github.io/ds-provider-postgresql-py-lib/
Development
git clone https://github.com/grasp-labs/ds-provider-postgresql-py-lib.git
cd ds-provider-postgresql-py-lib
uv sync --all-extras --dev
make test
License
Apache-2.0. See LICENSE-APACHE.
Support
Metadata
Release files for ds-provider-postgresql-py-lib 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ds_provider_postgresql_py_lib-0.1.0.tar.gz | 21.6 kB | Without provenance | Details for ds_provider_postgresql_py_lib-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ds_provider_postgresql_py_lib-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for ds_provider_postgresql_py_lib-0.1.0-py3-none-any.whl |
Total release size: 44.5 kB
Release files / ds_provider_postgresql_py_lib-0.1.0.tar.gz
| Download URL | ds_provider_postgresql_py_lib-0.1.0.tar.gz |
|---|---|
| Size | 21.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0d1d029704d5afac9dd45fe116ac1b38124ddb941fae018e4f7cfe2a82e1c430
|
|
BLAKE2b-256 checksum How to use checksums |
cc42f56434f280c8329f2f1a4f1cfe78f136ea6ddbb43507dd027d208bae4893
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Release files / ds_provider_postgresql_py_lib-0.1.0-py3-none-any.whl
| Download URL | ds_provider_postgresql_py_lib-0.1.0-py3-none-any.whl |
|---|---|
| Size | 22.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4ef1ae6f678b0ccb1bd91db68b2d03800d11c3c35ec779584ed51d6d2bcb9f02
|
|
BLAKE2b-256 checksum How to use checksums |
f0398d3b82a96e4c28efae914d2ce0f46f47320d78a6abb28eb4b6361fce9837
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Security for ds-provider-postgresql-py-lib 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.