Skip to content

Commit a9a92f0

Browse files
ctruedenclaude
andcommitted
Start porting builder+tool subsystem from Java
Co-authored-by: Claude <noreply@anthropic.com>
1 parent 897084c commit a9a92f0

32 files changed

Lines changed: 5134 additions & 52 deletions

.python-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.9
1+
3.9

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "appose"
7-
version = "0.7.3.dev0"
7+
version = "0.8.0.dev0"
88
description = "Appose: multi-language interprocess cooperation with shared memory."
99
license = "BSD-2-Clause"
1010
authors = [{name = "Appose developers"}]
@@ -16,6 +16,7 @@ classifiers = [
1616
"Intended Audience :: Education",
1717
"Intended Audience :: Science/Research",
1818
"Programming Language :: Python :: 3 :: Only",
19+
"Programming Language :: Python :: 3.9",
1920
"Programming Language :: Python :: 3.10",
2021
"Programming Language :: Python :: 3.11",
2122
"Programming Language :: Python :: 3.12",

src/appose/__init__.py

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -216,22 +216,32 @@ def task_listener(event):
216216

217217
from pathlib import Path
218218

219-
from .builder import Builder
219+
from .builder import SimpleBuilder
220220
from .environment import Environment
221221
from .shm import NDArray, SharedMemory # noqa: F401
222222

223223

224-
def base(directory: Path) -> Builder:
225-
return Builder().base(directory)
224+
def base(directory: Path) -> SimpleBuilder:
225+
"""
226+
Create a simple builder with a custom base directory.
226227
228+
Args:
229+
directory: The base directory for the environment
227230
228-
def java(vendor: str, version: str) -> Builder:
229-
return Builder().java(vendor=vendor, version=version)
231+
Returns:
232+
A SimpleBuilder instance configured with the given directory
233+
"""
234+
return SimpleBuilder().base(directory)
230235

231236

232-
def conda(environment_yaml: Path) -> Builder:
233-
return Builder().conda(environment_yaml=environment_yaml)
237+
def system(directory: Path = Path(".")) -> Environment:
238+
"""
239+
Create a simple environment using system executables.
234240
241+
Args:
242+
directory: The working directory (defaults to current directory)
235243
236-
def system(directory: Path = Path(".")) -> Environment:
237-
return Builder().base(directory).use_system_path().build()
244+
Returns:
245+
An Environment that uses system PATH for finding executables
246+
"""
247+
return SimpleBuilder().base(directory).append_system_path().build()

0 commit comments

Comments
 (0)