futurehouse-client 0.4.3.dev4__tar.gz → 0.4.4.dev1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {futurehouse_client-0.4.3.dev4/futurehouse_client.egg-info → futurehouse_client-0.4.4.dev1}/PKG-INFO +2 -2
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/docs/client_notebook.ipynb +3 -2
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/pyproject.toml +6 -3
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/clients/data_storage_methods.py +5 -5
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/clients/rest_client.py +0 -1
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/version.py +3 -3
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src/futurehouse_client.egg-info}/PKG-INFO +2 -2
- futurehouse_client-0.4.4.dev1/src/futurehouse_client.egg-info/SOURCES.txt +36 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client.egg-info/requires.txt +1 -1
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_client.py +5 -4
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data_storage_e2e.py +27 -2
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data_storage_methods.py +2 -23
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_rest.py +29 -26
- futurehouse_client-0.4.3.dev4/futurehouse_client.egg-info/SOURCES.txt +0 -36
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/LICENSE +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/README.md +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/data_storage.md +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/docs/__init__.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/setup.cfg +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/__init__.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/clients/__init__.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/clients/job_client.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/__init__.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/app.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/client.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/data_storage_methods.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/rest.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/py.typed +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/__init__.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/auth.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/general.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/module_utils.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/monitoring.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/world_model_tools.py +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client.egg-info/dependency_links.txt +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client.egg-info/top_level.txt +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_file.txt +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_information.txt +0 -0
- {futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_manifest.yaml +0 -0
{futurehouse_client-0.4.3.dev4/futurehouse_client.egg-info → futurehouse_client-0.4.4.dev1}/PKG-INFO
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: futurehouse-client
|
3
|
-
Version: 0.4.
|
3
|
+
Version: 0.4.4.dev1
|
4
4
|
Summary: A client for interacting with endpoints of the FutureHouse service.
|
5
5
|
Author-email: FutureHouse technical staff <hello@futurehouse.org>
|
6
6
|
License: Apache License
|
@@ -216,7 +216,7 @@ License-File: LICENSE
|
|
216
216
|
Requires-Dist: aiofiles
|
217
217
|
Requires-Dist: cloudpickle
|
218
218
|
Requires-Dist: fhaviary
|
219
|
-
Requires-Dist: google-resumable-media
|
219
|
+
Requires-Dist: google-resumable-media
|
220
220
|
Requires-Dist: httpx
|
221
221
|
Requires-Dist: ldp>=0.22.0
|
222
222
|
Requires-Dist: litellm
|
@@ -25,14 +25,15 @@
|
|
25
25
|
"metadata": {},
|
26
26
|
"outputs": [],
|
27
27
|
"source": [
|
28
|
+
"from ldp.agent import AgentConfig\n",
|
29
|
+
"\n",
|
28
30
|
"from futurehouse_client import FutureHouseClient, JobNames\n",
|
29
31
|
"from futurehouse_client.models import (\n",
|
30
32
|
" AuthType,\n",
|
31
33
|
" RuntimeConfig,\n",
|
32
34
|
" Stage,\n",
|
33
35
|
" TaskRequest,\n",
|
34
|
-
")
|
35
|
-
"from ldp.agent import AgentConfig"
|
36
|
+
")"
|
36
37
|
]
|
37
38
|
},
|
38
39
|
{
|
@@ -20,7 +20,7 @@ dependencies = [
|
|
20
20
|
"aiofiles",
|
21
21
|
"cloudpickle",
|
22
22
|
"fhaviary",
|
23
|
-
"google-resumable-media
|
23
|
+
"google-resumable-media",
|
24
24
|
"httpx",
|
25
25
|
"ldp>=0.22.0",
|
26
26
|
"litellm",
|
@@ -70,13 +70,16 @@ typing = [
|
|
70
70
|
"types-tqdm",
|
71
71
|
]
|
72
72
|
|
73
|
+
[tool.ruff]
|
74
|
+
extend = "../../pyproject.toml"
|
75
|
+
|
73
76
|
[tool.setuptools.packages.find]
|
74
|
-
|
77
|
+
where = ["src"]
|
75
78
|
|
76
79
|
[tool.setuptools_scm]
|
77
80
|
local_scheme = "no-local-version"
|
78
81
|
root = "../.."
|
79
|
-
version_file = "futurehouse_client/version.py"
|
82
|
+
version_file = "src/futurehouse_client/version.py"
|
80
83
|
|
81
84
|
[[tool.uv.index]]
|
82
85
|
explicit = true
|
@@ -476,7 +476,7 @@ class ProgressWrapper:
|
|
476
476
|
return self.file_obj.tell()
|
477
477
|
|
478
478
|
|
479
|
-
class DataStorageMethods:
|
479
|
+
class DataStorageMethods:
|
480
480
|
"""Data storage methods for RestClient.
|
481
481
|
|
482
482
|
This class contains methods for interacting with the data storage API endpoints.
|
@@ -1638,13 +1638,13 @@ class DataStorageMethods: # pylint: disable=too-many-public-methods
|
|
1638
1638
|
existing_location = DataStorageLocationPayload(
|
1639
1639
|
storage_type=DataStorageType.LINK,
|
1640
1640
|
content_type=DataContentType.TEXT,
|
1641
|
-
location=url,
|
1641
|
+
location=str(url),
|
1642
1642
|
metadata=link_metadata or None,
|
1643
1643
|
)
|
1644
1644
|
|
1645
1645
|
payload = DataStorageRequestPayload(
|
1646
1646
|
name=name,
|
1647
|
-
content=url,
|
1647
|
+
content=str(url),
|
1648
1648
|
description=description,
|
1649
1649
|
dataset_id=dataset_id,
|
1650
1650
|
project_id=project_id,
|
@@ -1697,13 +1697,13 @@ class DataStorageMethods: # pylint: disable=too-many-public-methods
|
|
1697
1697
|
existing_location = DataStorageLocationPayload(
|
1698
1698
|
storage_type=DataStorageType.LINK,
|
1699
1699
|
content_type=DataContentType.TEXT,
|
1700
|
-
location=url,
|
1700
|
+
location=str(url),
|
1701
1701
|
metadata=link_metadata or None,
|
1702
1702
|
)
|
1703
1703
|
|
1704
1704
|
payload = DataStorageRequestPayload(
|
1705
1705
|
name=name,
|
1706
|
-
content=url,
|
1706
|
+
content=str(url),
|
1707
1707
|
description=description,
|
1708
1708
|
dataset_id=dataset_id,
|
1709
1709
|
project_id=project_id,
|
@@ -165,7 +165,6 @@ retry_if_connection_error = create_retry_if_connection_error(FileUploadError)
|
|
165
165
|
DEFAULT_AGENT_TIMEOUT: int = 2400 # seconds
|
166
166
|
|
167
167
|
|
168
|
-
# pylint: disable=too-many-public-methods
|
169
168
|
class RestClient(DataStorageMethods):
|
170
169
|
REQUEST_TIMEOUT: ClassVar[float] = 30.0 # sec - for general API calls
|
171
170
|
FILE_UPLOAD_TIMEOUT: ClassVar[float] = 600.0 # 10 minutes - for file uploads
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/version.py
RENAMED
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
|
|
28
28
|
commit_id: COMMIT_ID
|
29
29
|
__commit_id__: COMMIT_ID
|
30
30
|
|
31
|
-
__version__ = version = '0.4.
|
32
|
-
__version_tuple__ = version_tuple = (0, 4,
|
31
|
+
__version__ = version = '0.4.4.dev1'
|
32
|
+
__version_tuple__ = version_tuple = (0, 4, 4, 'dev1')
|
33
33
|
|
34
|
-
__commit_id__ = commit_id = '
|
34
|
+
__commit_id__ = commit_id = 'g254eff27c'
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: futurehouse-client
|
3
|
-
Version: 0.4.
|
3
|
+
Version: 0.4.4.dev1
|
4
4
|
Summary: A client for interacting with endpoints of the FutureHouse service.
|
5
5
|
Author-email: FutureHouse technical staff <hello@futurehouse.org>
|
6
6
|
License: Apache License
|
@@ -216,7 +216,7 @@ License-File: LICENSE
|
|
216
216
|
Requires-Dist: aiofiles
|
217
217
|
Requires-Dist: cloudpickle
|
218
218
|
Requires-Dist: fhaviary
|
219
|
-
Requires-Dist: google-resumable-media
|
219
|
+
Requires-Dist: google-resumable-media
|
220
220
|
Requires-Dist: httpx
|
221
221
|
Requires-Dist: ldp>=0.22.0
|
222
222
|
Requires-Dist: litellm
|
@@ -0,0 +1,36 @@
|
|
1
|
+
LICENSE
|
2
|
+
README.md
|
3
|
+
data_storage.md
|
4
|
+
pyproject.toml
|
5
|
+
docs/__init__.py
|
6
|
+
docs/client_notebook.ipynb
|
7
|
+
src/futurehouse_client/__init__.py
|
8
|
+
src/futurehouse_client/py.typed
|
9
|
+
src/futurehouse_client/version.py
|
10
|
+
src/futurehouse_client.egg-info/PKG-INFO
|
11
|
+
src/futurehouse_client.egg-info/SOURCES.txt
|
12
|
+
src/futurehouse_client.egg-info/dependency_links.txt
|
13
|
+
src/futurehouse_client.egg-info/requires.txt
|
14
|
+
src/futurehouse_client.egg-info/top_level.txt
|
15
|
+
src/futurehouse_client/clients/__init__.py
|
16
|
+
src/futurehouse_client/clients/data_storage_methods.py
|
17
|
+
src/futurehouse_client/clients/job_client.py
|
18
|
+
src/futurehouse_client/clients/rest_client.py
|
19
|
+
src/futurehouse_client/models/__init__.py
|
20
|
+
src/futurehouse_client/models/app.py
|
21
|
+
src/futurehouse_client/models/client.py
|
22
|
+
src/futurehouse_client/models/data_storage_methods.py
|
23
|
+
src/futurehouse_client/models/rest.py
|
24
|
+
src/futurehouse_client/utils/__init__.py
|
25
|
+
src/futurehouse_client/utils/auth.py
|
26
|
+
src/futurehouse_client/utils/general.py
|
27
|
+
src/futurehouse_client/utils/module_utils.py
|
28
|
+
src/futurehouse_client/utils/monitoring.py
|
29
|
+
src/futurehouse_client/utils/world_model_tools.py
|
30
|
+
tests/test_client.py
|
31
|
+
tests/test_data_storage_e2e.py
|
32
|
+
tests/test_data_storage_methods.py
|
33
|
+
tests/test_rest.py
|
34
|
+
tests/test_data/test_file.txt
|
35
|
+
tests/test_data/test_information.txt
|
36
|
+
tests/test_data/test_manifest.yaml
|
@@ -5,12 +5,13 @@ from unittest.mock import MagicMock
|
|
5
5
|
|
6
6
|
import httpx
|
7
7
|
import pytest
|
8
|
+
|
8
9
|
from futurehouse_client.models.app import AuthType, TaskResponse
|
9
10
|
from futurehouse_client.utils.auth import RefreshingJWT
|
10
11
|
|
11
12
|
|
12
|
-
@pytest.fixture
|
13
|
-
def
|
13
|
+
@pytest.fixture(name="mock_client")
|
14
|
+
def fixture_mock_client():
|
14
15
|
"""Create a mock synchronous HTTP client that returns success on first auth attempt."""
|
15
16
|
client = MagicMock(spec=httpx.Client)
|
16
17
|
response = MagicMock()
|
@@ -23,8 +24,8 @@ def mock_client():
|
|
23
24
|
return client
|
24
25
|
|
25
26
|
|
26
|
-
@pytest.fixture
|
27
|
-
def
|
27
|
+
@pytest.fixture(name="failing_then_success_client")
|
28
|
+
def fixture_failing_then_success_client():
|
28
29
|
"""Create a client that fails with 401 on first call, then succeeds on retry."""
|
29
30
|
client = MagicMock(spec=httpx.Client)
|
30
31
|
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data_storage_e2e.py
RENAMED
@@ -4,6 +4,8 @@ from pathlib import Path
|
|
4
4
|
from uuid import uuid4
|
5
5
|
|
6
6
|
import pytest
|
7
|
+
from pydantic import HttpUrl
|
8
|
+
|
7
9
|
from futurehouse_client.clients.data_storage_methods import DataStorageError
|
8
10
|
from futurehouse_client.clients.rest_client import (
|
9
11
|
RestClient,
|
@@ -20,8 +22,8 @@ from futurehouse_client.models.data_storage_methods import (
|
|
20
22
|
ADMIN_API_KEY = os.environ["PLAYWRIGHT_ADMIN_API_KEY"]
|
21
23
|
|
22
24
|
|
23
|
-
@pytest.fixture
|
24
|
-
def
|
25
|
+
@pytest.fixture(name="admin_client")
|
26
|
+
def fixture_admin_client():
|
25
27
|
"""Create a RestClient for testing; using a admin user key with full access."""
|
26
28
|
return RestClient(
|
27
29
|
stage=Stage.DEV,
|
@@ -482,3 +484,26 @@ def test_dataset_sync(admin_client: RestClient):
|
|
482
484
|
|
483
485
|
with pytest.raises(DataStorageError, match="Failed to get dataset"):
|
484
486
|
admin_client.get_dataset(dataset_id=create_response.id)
|
487
|
+
|
488
|
+
|
489
|
+
@pytest.mark.asyncio
|
490
|
+
async def test_astore_link_success(admin_client: RestClient):
|
491
|
+
"""Test successful asynchronous link storage."""
|
492
|
+
result = await admin_client.astore_link(
|
493
|
+
name="Test API Link",
|
494
|
+
url=HttpUrl("https://xyz.api.futurehouse.org"),
|
495
|
+
description="Test link to xyz.api.futurehouse.org",
|
496
|
+
instructions="this is a test api which you can call without authentication",
|
497
|
+
api_key="test_key_123",
|
498
|
+
)
|
499
|
+
|
500
|
+
assert result.data_storage.id is not None
|
501
|
+
assert result.data_storage.name == "Test API Link"
|
502
|
+
assert result.data_storage.description == "Test link to xyz.api.futurehouse.org"
|
503
|
+
assert result.data_storage.content == "https://xyz.api.futurehouse.org/"
|
504
|
+
assert len(result.storage_locations) > 0
|
505
|
+
assert result.storage_locations[0].storage_config.storage_type == "link"
|
506
|
+
assert (
|
507
|
+
result.storage_locations[0].storage_config.location
|
508
|
+
== "https://xyz.api.futurehouse.org/"
|
509
|
+
)
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data_storage_methods.py
RENAMED
@@ -7,6 +7,8 @@ from unittest.mock import ANY, AsyncMock, Mock, patch
|
|
7
7
|
from uuid import uuid4
|
8
8
|
|
9
9
|
import pytest
|
10
|
+
from httpx import HTTPStatusError, codes
|
11
|
+
|
10
12
|
from futurehouse_client.clients.data_storage_methods import (
|
11
13
|
DataStorageCreationError,
|
12
14
|
DataStorageError,
|
@@ -21,8 +23,6 @@ from futurehouse_client.models.data_storage_methods import (
|
|
21
23
|
DirectoryManifest,
|
22
24
|
ManifestEntry,
|
23
25
|
)
|
24
|
-
from httpx import HTTPStatusError, codes
|
25
|
-
from pydantic import HttpUrl
|
26
26
|
|
27
27
|
|
28
28
|
class MockDataStorageMethods(DataStorageMethods):
|
@@ -1232,27 +1232,6 @@ class TestDataStorageMethods:
|
|
1232
1232
|
with pytest.raises(DataStorageError, match="Data storage entry not found"):
|
1233
1233
|
await self.methods.adelete_data_storage_entry(entry_id)
|
1234
1234
|
|
1235
|
-
@pytest.mark.asyncio
|
1236
|
-
async def test_astore_link_success(self):
|
1237
|
-
result = await self.methods.astore_link(
|
1238
|
-
name="Test API Link",
|
1239
|
-
url=HttpUrl("https://xyz.api.futurehouse.org"),
|
1240
|
-
description="Test link to xyz.api.futurehouse.org",
|
1241
|
-
instructions="this is a test api which you can call without authentication",
|
1242
|
-
api_key="test_key_123",
|
1243
|
-
)
|
1244
|
-
|
1245
|
-
assert result.data_storage.id is not None
|
1246
|
-
assert result.data_storage.name == "Test API Link"
|
1247
|
-
assert result.data_storage.description == "Test link to xyz.api.futurehouse.org"
|
1248
|
-
assert result.data_storage.content == "https://xyz.api.futurehouse.org"
|
1249
|
-
assert len(result.storage_locations) > 0
|
1250
|
-
assert result.storage_locations[0].storage_config.storage_type == "link"
|
1251
|
-
assert (
|
1252
|
-
result.storage_locations[0].storage_config.location
|
1253
|
-
== "https://xyz.api.futurehouse.org"
|
1254
|
-
)
|
1255
|
-
|
1256
1235
|
|
1257
1236
|
class TestUtilityFunctions:
|
1258
1237
|
"""Test cases for utility functions."""
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# ruff: noqa: ARG001
|
2
|
-
# ruff:
|
3
|
-
|
2
|
+
# ruff: noqa: SIM117
|
3
|
+
|
4
4
|
import asyncio
|
5
5
|
import os
|
6
6
|
import tempfile
|
@@ -12,6 +12,19 @@ from unittest.mock import MagicMock, Mock, mock_open, patch
|
|
12
12
|
from uuid import UUID, uuid4
|
13
13
|
|
14
14
|
import pytest
|
15
|
+
from httpx import (
|
16
|
+
CloseError,
|
17
|
+
ConnectError,
|
18
|
+
ConnectTimeout,
|
19
|
+
HTTPStatusError,
|
20
|
+
NetworkError,
|
21
|
+
ReadError,
|
22
|
+
ReadTimeout,
|
23
|
+
RemoteProtocolError,
|
24
|
+
)
|
25
|
+
from pytest_subtests import SubTests
|
26
|
+
from requests.exceptions import RequestException, Timeout
|
27
|
+
|
15
28
|
from futurehouse_client.clients import (
|
16
29
|
JobNames,
|
17
30
|
)
|
@@ -38,26 +51,14 @@ from futurehouse_client.models.rest import (
|
|
38
51
|
WorldModel,
|
39
52
|
)
|
40
53
|
from futurehouse_client.utils.general import create_retry_if_connection_error
|
41
|
-
from httpx import (
|
42
|
-
CloseError,
|
43
|
-
ConnectError,
|
44
|
-
ConnectTimeout,
|
45
|
-
HTTPStatusError,
|
46
|
-
NetworkError,
|
47
|
-
ReadError,
|
48
|
-
ReadTimeout,
|
49
|
-
RemoteProtocolError,
|
50
|
-
)
|
51
|
-
from pytest_subtests import SubTests
|
52
|
-
from requests.exceptions import RequestException, Timeout
|
53
54
|
|
54
55
|
ADMIN_API_KEY = os.environ.get("PLAYWRIGHT_ADMIN_API_KEY", "")
|
55
56
|
PUBLIC_API_KEY = os.environ.get("PLAYWRIGHT_PUBLIC_API_KEY", "")
|
56
57
|
TEST_MAX_POLLS = 100
|
57
58
|
|
58
59
|
|
59
|
-
@pytest.fixture
|
60
|
-
def
|
60
|
+
@pytest.fixture(name="admin_client")
|
61
|
+
def fixture_admin_client():
|
61
62
|
"""Create a RestClient for testing; using an admin key."""
|
62
63
|
return RestClient(
|
63
64
|
stage=Stage.DEV,
|
@@ -65,8 +66,8 @@ def admin_client():
|
|
65
66
|
)
|
66
67
|
|
67
68
|
|
68
|
-
@pytest.fixture
|
69
|
-
def
|
69
|
+
@pytest.fixture(name="pub_client")
|
70
|
+
def fixture_pub_client():
|
70
71
|
"""Create a RestClient for testing; using a public user key with limited access."""
|
71
72
|
return RestClient(
|
72
73
|
stage=Stage.DEV,
|
@@ -74,8 +75,8 @@ def pub_client():
|
|
74
75
|
)
|
75
76
|
|
76
77
|
|
77
|
-
@pytest.fixture
|
78
|
-
def
|
78
|
+
@pytest.fixture(name="task_req")
|
79
|
+
def fixture_task_req():
|
79
80
|
"""Create a sample task request."""
|
80
81
|
return TaskRequest(
|
81
82
|
name=JobNames.from_string("dummy"),
|
@@ -83,24 +84,26 @@ def task_req():
|
|
83
84
|
)
|
84
85
|
|
85
86
|
|
86
|
-
@pytest.fixture
|
87
|
-
def
|
87
|
+
@pytest.fixture(name="pqa_task_req")
|
88
|
+
def fixture_pqa_task_req():
|
88
89
|
return TaskRequest(
|
89
90
|
name=JobNames.from_string("crow"),
|
90
91
|
query="How many moons does earth have?",
|
91
92
|
)
|
92
93
|
|
93
94
|
|
94
|
-
@pytest.fixture
|
95
|
-
def
|
95
|
+
@pytest.fixture(name="phoenix_task_req")
|
96
|
+
def fixture_phoenix_task_req():
|
96
97
|
return TaskRequest(
|
97
98
|
name=JobNames.from_string("phoenix"),
|
98
99
|
query="What is the molecular weight of ascorbic acids?",
|
99
100
|
)
|
100
101
|
|
101
102
|
|
102
|
-
@pytest.fixture
|
103
|
-
def
|
103
|
+
@pytest.fixture(name="running_trajectory_id")
|
104
|
+
def fixture_running_trajectory_id(
|
105
|
+
admin_client: RestClient, task_req: TaskRequest
|
106
|
+
) -> str:
|
104
107
|
return admin_client.create_task(task_req)
|
105
108
|
|
106
109
|
|
@@ -1,36 +0,0 @@
|
|
1
|
-
LICENSE
|
2
|
-
README.md
|
3
|
-
data_storage.md
|
4
|
-
pyproject.toml
|
5
|
-
docs/__init__.py
|
6
|
-
docs/client_notebook.ipynb
|
7
|
-
futurehouse_client/__init__.py
|
8
|
-
futurehouse_client/py.typed
|
9
|
-
futurehouse_client/version.py
|
10
|
-
futurehouse_client.egg-info/PKG-INFO
|
11
|
-
futurehouse_client.egg-info/SOURCES.txt
|
12
|
-
futurehouse_client.egg-info/dependency_links.txt
|
13
|
-
futurehouse_client.egg-info/requires.txt
|
14
|
-
futurehouse_client.egg-info/top_level.txt
|
15
|
-
futurehouse_client/clients/__init__.py
|
16
|
-
futurehouse_client/clients/data_storage_methods.py
|
17
|
-
futurehouse_client/clients/job_client.py
|
18
|
-
futurehouse_client/clients/rest_client.py
|
19
|
-
futurehouse_client/models/__init__.py
|
20
|
-
futurehouse_client/models/app.py
|
21
|
-
futurehouse_client/models/client.py
|
22
|
-
futurehouse_client/models/data_storage_methods.py
|
23
|
-
futurehouse_client/models/rest.py
|
24
|
-
futurehouse_client/utils/__init__.py
|
25
|
-
futurehouse_client/utils/auth.py
|
26
|
-
futurehouse_client/utils/general.py
|
27
|
-
futurehouse_client/utils/module_utils.py
|
28
|
-
futurehouse_client/utils/monitoring.py
|
29
|
-
futurehouse_client/utils/world_model_tools.py
|
30
|
-
tests/test_client.py
|
31
|
-
tests/test_data_storage_e2e.py
|
32
|
-
tests/test_data_storage_methods.py
|
33
|
-
tests/test_rest.py
|
34
|
-
tests/test_data/test_file.txt
|
35
|
-
tests/test_data/test_information.txt
|
36
|
-
tests/test_data/test_manifest.yaml
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/__init__.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/models/app.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/py.typed
RENAMED
File without changes
|
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1/src}/futurehouse_client/utils/auth.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_file.txt
RENAMED
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_information.txt
RENAMED
File without changes
|
{futurehouse_client-0.4.3.dev4 → futurehouse_client-0.4.4.dev1}/tests/test_data/test_manifest.yaml
RENAMED
File without changes
|