Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 19 additions & 10 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "vip-client"
description = "Python client to use the Virtual Imaging Platform (VIP) through its RESTful API."
license = "CECILL-B"
version = "0.1.9"
authors = [
{ name="Gaël Vila", email="gael.vila@creatis.insa-lyon.fr" },
]
Expand All @@ -26,16 +24,15 @@ classifiers = [
"Topic :: Scientific/Engineering :: Medical Science Apps.",
]
dependencies = ["requests", "girder-client"]
dynamic = ["version"] # see [tool.hatch.version]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

# Only build files inside src/vip_client
[tool.hatch.build.targets.wheel]
packages = ["src/vip_client"]

# File where the software version should be found
[tool.hatch.version]
path = "src/vip_client/__init__.py"

[tool.pytest.ini_options]
pythonpath = [
"src"
Expand All @@ -44,4 +41,16 @@ pythonpath = [
[project.urls]
Homepage = "https://vip.creatis.insa-lyon.fr"
Source = "https://github.com/virtual-imaging-platform/VIP-python-client"
Tracker = "https://github.com/virtual-imaging-platform/VIP-python-client/issues"
Tracker = "https://github.com/virtual-imaging-platform/VIP-python-client/issues"

[[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
publish-url = "https://test.pypi.org/legacy/"
explicit = true

[[tool.uv.index]]
name = "nexus-snapshots"
url = "https://vip.creatis.insa-lyon.fr:9007/nexus/repository/pypi-snapshot/simple/"
publish-url = "https://vip.creatis.insa-lyon.fr:9007/nexus/repository/pypi-snapshot/"
explicit = true
21 changes: 9 additions & 12 deletions src/vip_client/__init__.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
"""
Python client for the Virtual Imaging Platform (VIP): https://vip.creatis.insa-lyon.fr/.
from vip_client.classes.VipGirder import VipGirder
from vip_client.classes.VipLauncher import VipLauncher
from vip_client.classes.VipSession import VipSession

Python classes and methods to interact with VIP through its RESTful API.
Main user class: VipSession
from vip_client import VipSession
For more information: https://github.com/virtual-imaging-platform/VIP-python-client.
"""
All classes for the client.
- VipSession: main user class. To run a VIP application on local datasets.
- VipLauncher: to run a Vip application on datasets located on VIP servers.
- VipGirder: to run a Vip application on datasets located on CREATIS data warehouse.
"""

# Informations
__version__ = "0.1.9"
__license__ = "CECILL-B"

from vip_client.classes import VipSession
from vip_client.classes import VipGirder
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we not keep the 2 imports ?
I think that without them the imports like from vip_client import VipSession will fail.

__all__ = ["VipGirder", "VipLauncher", "VipSession"]
13 changes: 0 additions & 13 deletions src/vip_client/classes/__init__.py

This file was deleted.

2 changes: 1 addition & 1 deletion tests/test_VipGirder.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import pytest
from pathlib import *

from vip_client.classes import VipGirder
from vip_client import VipGirder
from mocked_services import mock_vip_api, mock_girder_client, mock_pathlib, mock_os
from FakeGirderClient import FakeGirderClient

Expand Down
2 changes: 1 addition & 1 deletion tests/test_VipLauncher.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import pytest
from pathlib import *

from vip_client.classes import VipLauncher
from vip_client import VipLauncher
from mocked_services import mock_vip_api, mock_pathlib, mock_os


Expand Down
2 changes: 1 addition & 1 deletion tests/test_VipSession.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import pytest
from pathlib import *

from vip_client.classes import VipSession
from vip_client import VipSession
from mocked_services import mock_vip_api, mock_pathlib, mock_os

def get_properties(obj) -> dict:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_global.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from vip_client.classes import VipSession, VipGirder, VipLauncher
from vip_client import VipSession, VipGirder, VipLauncher
from mocked_services import mock_vip_api, mock_pathlib, mock_os, mock_girder_client
import pytest

Expand Down
404 changes: 404 additions & 0 deletions uv.lock

Large diffs are not rendered by default.