From 18c5a34e14a3b1660dd68046a59ea3857e6d9de1 Mon Sep 17 00:00:00 2001 From: Yannick Marcon Date: Sun, 3 May 2026 09:13:59 +0200 Subject: [PATCH] feat: added id to DSSession --- datashield/api.py | 3 ++- pyproject.toml | 2 +- uv.lock | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/datashield/api.py b/datashield/api.py index 08251ab..4caf3b2 100644 --- a/datashield/api.py +++ b/datashield/api.py @@ -1,7 +1,7 @@ """ DataSHIELD API. """ - +import uuid import logging from datashield.interface import DSConfig, DSLoginInfo, DSConnection, DSDriver, DSError import time @@ -19,6 +19,7 @@ def __init__(self, names: list[str] = None): :param names: The list of server names to load from configuration files, if any. If not defined, no login information will be loaded from configuration files. """ + self.id = str(uuid.uuid4()) self.items: list[DSLoginInfo] = [] # load login information from configuration files, in order of precedence if names is not None and len(names) > 0: diff --git a/pyproject.toml b/pyproject.toml index 529b7e8..1044de7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "datashield" -version = "0.4.0" +version = "0.5.0" description = "DataSHIELD Client Interface in Python." authors = [ {name = "Yannick Marcon", email = "yannick.marcon@obiba.org"} diff --git a/uv.lock b/uv.lock index b68e040..cd78991 100644 --- a/uv.lock +++ b/uv.lock @@ -22,7 +22,7 @@ wheels = [ [[package]] name = "datashield" -version = "0.4.0" +version = "0.5.0" source = { editable = "." } dependencies = [ { name = "pydantic" },