ap-client 0.6.1.dev9__tar.gz → 0.6.1.dev10__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.
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/PKG-INFO +1 -1
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/irepo_sdk.py +39 -1
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/pyproject.toml +1 -1
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/__init__.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/akpool_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/api.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/cli.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/config.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/dataset_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/dataset_name.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/dataset_register.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/dfs_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/exporter.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/fs_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/instance_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/instance_options.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/managed_ak.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/manifest_view.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/ossutil_hash.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/ossutil_io.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/profile_commands.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/repo_read_guard.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/share_api.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/split_publish.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/tbb.py +0 -0
- {ap_client-0.6.1.dev9 → ap_client-0.6.1.dev10}/ap_client/waiter.py +0 -0
|
@@ -955,7 +955,9 @@ def load_repo(
|
|
|
955
955
|
_Transport = None
|
|
956
956
|
if _Transport is not None:
|
|
957
957
|
kwargs["transport"] = _Transport(
|
|
958
|
-
cfg.base_url,
|
|
958
|
+
cfg.base_url,
|
|
959
|
+
cfg.token_key or "",
|
|
960
|
+
env=api_env,
|
|
959
961
|
timeout=request_timeout,
|
|
960
962
|
)
|
|
961
963
|
|
|
@@ -968,9 +970,45 @@ def load_repo(
|
|
|
968
970
|
repo = _Repo(**kwargs)
|
|
969
971
|
_bind_dataset_profile(repo)
|
|
970
972
|
_install_oss_probe_cache(repo, verbose=cfg.verbose)
|
|
973
|
+
_install_user_data_directory_listing(repo)
|
|
971
974
|
return repo
|
|
972
975
|
|
|
973
976
|
|
|
977
|
+
def _install_user_data_directory_listing(repo: Any) -> bool:
|
|
978
|
+
"""Keep the directory boundary lost by instance-repo 1.4.0 list_user_data.
|
|
979
|
+
|
|
980
|
+
Use the SDK's path validation and content store so STS authorization,
|
|
981
|
+
endpoint selection and pagination retain their normal behavior. Normalize
|
|
982
|
+
here until the SDK dependency includes its directory-prefix fix.
|
|
983
|
+
"""
|
|
984
|
+
content = getattr(repo, "_content", None)
|
|
985
|
+
prefix_for = getattr(repo, "_user_data_prefix", None)
|
|
986
|
+
clean = getattr(repo, "_clean_user_data_subpath", None)
|
|
987
|
+
if not all(
|
|
988
|
+
callable(fn)
|
|
989
|
+
for fn in (
|
|
990
|
+
getattr(repo, "list_user_data", None),
|
|
991
|
+
prefix_for,
|
|
992
|
+
clean,
|
|
993
|
+
getattr(content, "list_objects", None),
|
|
994
|
+
)
|
|
995
|
+
):
|
|
996
|
+
return False
|
|
997
|
+
|
|
998
|
+
def list_user_data(uid: str, subpath: str = "") -> list[str]:
|
|
999
|
+
from instance_repo.errors import SchemaError
|
|
1000
|
+
|
|
1001
|
+
if not str(uid).strip():
|
|
1002
|
+
raise SchemaError("uid must not be empty")
|
|
1003
|
+
prefix = prefix_for(uid)
|
|
1004
|
+
if str(subpath).strip():
|
|
1005
|
+
prefix += clean(subpath) + "/"
|
|
1006
|
+
return content.list_objects(prefix)
|
|
1007
|
+
|
|
1008
|
+
repo.list_user_data = list_user_data
|
|
1009
|
+
return True
|
|
1010
|
+
|
|
1011
|
+
|
|
974
1012
|
def _bind_dataset_profile(repo: Any) -> None:
|
|
975
1013
|
"""Supply the configured context missing from SDK 1.3.5 dataset discovery.
|
|
976
1014
|
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "ap-client"
|
|
7
|
-
version = "0.6.1.
|
|
7
|
+
version = "0.6.1.dev10"
|
|
8
8
|
description = "Agent Platform API Client & CLI"
|
|
9
9
|
readme = { text = "A lightweight Python SDK and command line interface for Agent Platform. It provides helpers for configuring API access and managing templates, datasets, jobs, and groups.", content-type = "text/markdown" }
|
|
10
10
|
requires-python = ">=3.10"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|