Install & Compatibility
Where this runs
tested against v0.0.4 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 30MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 2.0s · import 0.000s · 30MB
28MB installed
● package 28MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
get_local_path
✓ from label_studio_tools.core.utils.io import get_local_path
✗ from label_studio_tools.core.utils.io import get_local_path
Parse a config XML and get local path for a file. For storage downloads, set LS_API_KEY environment variable and provide a task_id.
from label_studio_tools.core.utils.io import get_local_path
from label_studio_tools.core.utils.config import parse_config
# Parse a Label Studio config XML string
config_xml = """<View><Text name="text" value="$text"/><Choices name="label" toName="text"><Choice value="A"/><Choice value="B"/></Choices></View>"""
parsed = parse_config(config_xml)
print(parsed)
# Get local path for a task's data (requires LS_API_KEY env var for non-local storage)
import os
os.environ['LS_API_KEY'] = os.environ.get('LS_API_KEY', '')
# task_id is needed for storage downloads; for local files, just provide the path
try:
path = get_local_path('/path/to/data', task_id=123)
print(path)
except Exception as e:
print(e)
Upgrade
Version history
0.0.4latest on PyPI · released Apr 29, 2024
Audit
Dependencies
No dependency data recorded yet.