Skip to content

Commit 41b5f97

Browse files
committed
away rebranding
1 parent a43c7f1 commit 41b5f97

98 files changed

Lines changed: 1708 additions & 1047 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/integration.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
with:
2525
python-version: ${{ matrix.python-version }}
2626

27-
- name: Install pyfuse + dev deps
27+
- name: Install away + dev deps
2828
run: |
2929
pip install -e ".[redis,rabbitmq]"
3030
pip install pytest pytest-asyncio
@@ -80,7 +80,7 @@ jobs:
8080
python-version: "3.13"
8181

8282
# --- Install --------------------------------------------------------
83-
- name: Install pyfuse + backend extras
83+
- name: Install away + backend extras
8484
run: |
8585
pip install -e ".[${{ matrix.backend.extras }}]"
8686
pip install pytest pytest-asyncio pytest-timeout
@@ -94,15 +94,15 @@ jobs:
9494
- name: Generate signing token
9595
if: matrix.signing
9696
run: |
97-
TOKEN=$(python -c "from pyfuse.core.token import generate_token; print(generate_token())")
98-
echo "PYFUSE_SIGNING_TOKEN=$TOKEN" >> "$GITHUB_ENV"
97+
TOKEN=$(python -c "from away.core.token import generate_token; print(generate_token())")
98+
echo "AWAY_SIGNING_TOKEN=$TOKEN" >> "$GITHUB_ENV"
9999
100100
# --- Run e2e tests --------------------------------------------------
101101
- name: Run end-to-end tests
102102
env:
103-
PYFUSE_TEST_BACKEND: ${{ matrix.backend.url }}
104-
PYFUSE_TEST_SIGNING: ${{ matrix.signing && '1' || '0' }}
105-
PYFUSE_TEST_SANDBOX: ${{ matrix.sandbox && '1' || '0' }}
103+
AWAY_TEST_BACKEND: ${{ matrix.backend.url }}
104+
AWAY_TEST_SIGNING: ${{ matrix.signing && '1' || '0' }}
105+
AWAY_TEST_SANDBOX: ${{ matrix.sandbox && '1' || '0' }}
106106
run: pytest tests/test_e2e.py -x -v --timeout=120
107107

108108
# --- Dump worker logs on failure ------------------------------------
@@ -111,7 +111,7 @@ jobs:
111111
run: |
112112
echo "=== Worker process logs ==="
113113
# Collected by the test fixtures via subprocess
114-
cat /tmp/pyfuse-worker-*.log 2>/dev/null || echo "(no log files)"
114+
cat /tmp/away-worker-*.log 2>/dev/null || echo "(no log files)"
115115
116116
# -----------------------------------------------------------------------
117117
# Mypy type checking
@@ -124,10 +124,10 @@ jobs:
124124
with:
125125
python-version: "3.13"
126126

127-
- name: Install pyfuse + dev deps
127+
- name: Install away + dev deps
128128
run: |
129129
pip install -e ".[redis,rabbitmq]"
130130
pip install mypy pytest pytest-asyncio
131131
132132
- name: Run mypy
133-
run: mypy pyfuse/
133+
run: mypy away/

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,6 @@ poetry.lock
1111
dist/
1212
build/
1313
.DS_Store
14-
.claudeignore
14+
.claudeignore
15+
node_modules/
16+
cloud_poc/frontend/dist/

README.md

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# pyfuse
1+
# away
22

33
**Run any Python function on a remote worker — zero setup, zero deployment.**
44

@@ -7,21 +7,21 @@
77
[![Typed](https://img.shields.io/badge/typing-strict%20mypy-blue)](https://mypy-lang.org/)
88
[![Zero Dependencies](https://img.shields.io/badge/dependencies-0-brightgreen)]()
99

10-
Add `@trace` to a function. pyfuse captures its source, dependencies, and imports automatically.
10+
Add `@trace` to a function. away captures its source, dependencies, and imports automatically.
1111
Workers reconstruct and execute everything from scratch — no shared filesystem, no deployment pipeline.
1212
Missing packages are installed on the fly.
1313

1414
## Quick start
1515

1616
```bash
17-
pip install pyfuse
17+
pip install away
1818
```
1919

2020
```python
21-
import asyncio, math, pyfuse
22-
from pyfuse import trace
21+
import asyncio, math, away
22+
from away import trace
2323

24-
pyfuse.connect("local://localhost:9748")
24+
away.connect("local://localhost:9748")
2525

2626
def add(a, b):
2727
return a + b
@@ -39,19 +39,19 @@ asyncio.run(main())
3939
Only the entry point needs `@trace` — everything it calls is captured automatically.
4040

4141
```bash
42-
pyfuse worker --backend local://localhost:9748 --tmp # start a worker
42+
away worker --backend local://localhost:9748 --tmp # start a worker
4343
python my_script.py # → 5.0
4444
```
4545

46-
For multi-machine, swap `local://` for `redis://`. That's it.
46+
For multi-machine, swap `local://` for `redis://` or an `https://` managed broker URL. That's it.
4747

4848
## Sandbox
4949

5050
Run tasks inside Docker containers for isolation — transparent to clients:
5151

5252
```bash
53-
pyfuse sandbox setup # build image (once)
54-
pyfuse worker --backend redis://localhost:6379 --sandbox # run with isolation
53+
away sandbox setup # build image (once)
54+
away worker --backend redis://localhost:6379 --sandbox # run with isolation
5555
```
5656

5757
See [Sandbox](docs/SANDBOX.md) for configuration and management.
@@ -62,13 +62,13 @@ Pre-shared token or PIN-based pairing + HMAC-SHA256 — workers reject untrusted
6262

6363
```bash
6464
# Token-based (recommended for CI/CD)
65-
pyfuse token generate # generate once
66-
export PYFUSE_SIGNING_TOKEN=<token> # set on client & worker
67-
pyfuse worker --backend redis://localhost:6379 --require-signing
65+
away token generate # generate once
66+
export AWAY_SIGNING_TOKEN=<token> # set on client & worker
67+
away worker --backend redis://localhost:6379 --require-signing
6868

6969
# PIN-based pairing (interactive)
70-
pyfuse worker --backend redis://localhost:6379 --pair # displays a 6-digit PIN
71-
pyfuse pair --backend redis://localhost:6379 # on client: enter the PIN
70+
away worker --backend redis://localhost:6379 --pair # displays a 6-digit PIN
71+
away pair --backend redis://localhost:6379 # on client: enter the PIN
7272
```
7373

7474
After setup, tasks are signed automatically. No client-side code changes. See [Signing & Pairing](docs/SIGNING.md) for details.
@@ -83,10 +83,10 @@ After setup, tasks are signed automatically. No client-side code changes. See [S
8383
| **Retry & timeout** | `@trace(timeout=30, retries=3)` with exponential backoff |
8484
| **Scheduling** | `.run_in(delay)`, `.run_at(datetime)`, `.run_every(freq)` with cancellation |
8585
| **Throttling** | `@trace(throttle=timedelta(hours=24)/50)` — rate-limit executions |
86-
| **Progress & cancellation** | `pyfuse.progress(3, 10)` inside tasks; `await future.cancel()` on client |
86+
| **Progress & cancellation** | `away.progress(3, 10)` inside tasks; `await future.cancel()` on client |
8787
| **Heartbeat & stall detection** | Workers heartbeat; clients raise `TaskStalled` on silence |
8888
| **Content-hash caching** | Same code = cache hit, regardless of client |
89-
| **Pluggable backends** | `local://` (same-machine TCP), `redis://`, `amqp://` (RabbitMQ) |
89+
| **Pluggable backends** | `local://` (same-machine TCP), `redis://`, `amqp://` (RabbitMQ), `http://`/`https://` (hosted broker API) |
9090
| **Docker sandbox** | Container isolation, transparent to clients |
9191
| **Signed execution** | Pre-shared token or PIN pairing + HMAC-SHA256 task authentication |
9292
| **Graceful shutdown** | Ctrl+C drains in-flight tasks; second Ctrl+C force-quits |
@@ -99,12 +99,13 @@ After setup, tasks are signed automatically. No client-side code changes. See [S
9999
| **[Technical Overview](docs/TECHNICAL_OVERVIEW.md)** | Architecture, serialization format, internals |
100100
| **[Signing & Pairing](docs/SIGNING.md)** | Cryptographic task signing protocol |
101101
| **[Sandbox](docs/SANDBOX.md)** | Docker container isolation |
102+
| **[Cloud POC](docs/CLOUD_POC.md)** | Local FastAPI + MongoDB + Kubernetes + React prototype for managed hosting |
102103

103104
## Examples
104105

105106
```bash
106-
pyfuse worker --backend local://localhost:9748 --tmp
107-
pyfuse run examples/remote_execution.py
107+
away worker --backend local://localhost:9748 --tmp
108+
away run examples/remote_execution.py
108109
```
109110

110111
[`remote_execution.py`](examples/remote_execution.py) · [`async_execution.py`](examples/async_execution.py) · [`package_installation.py`](examples/package_installation.py) · [`progress_reporting.py`](examples/progress_reporting.py) · [`cancellation.py`](examples/cancellation.py) · [`scheduling.py`](examples/scheduling.py) · [`throttling_and_retry.py`](examples/throttling_and_retry.py) · [`large_module.py`](examples/large_module.py)
Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
"""Public API for pyfuse — remote Python function execution."""
1+
"""Public API for away — remote Python function execution."""
22

33
import inspect
44
from typing import Any
55
from collections.abc import Callable
66

7-
from pyfuse.core.task import Task
8-
from pyfuse.core.errors import (
7+
from away.core.task import Task
8+
from away.core.errors import (
99
Error,
1010
RemoteError,
1111
TaskStalled,
@@ -17,11 +17,11 @@
1717
ThrottleError,
1818
WorkerOnlyError,
1919
)
20-
from pyfuse.core.models import ImportInfo, FunctionNode
21-
from pyfuse.graph.graph import Graph
22-
from pyfuse.graph.store import Store, MergeResult
23-
from pyfuse.worker.deps import install_package_as, worker_only_import
24-
from pyfuse.core.pairing import (
20+
from away.core.models import ImportInfo, FunctionNode
21+
from away.graph.graph import Graph
22+
from away.graph.store import Store, MergeResult
23+
from away.worker.deps import install_package_as, worker_only_import
24+
from away.core.pairing import (
2525
PairingResult,
2626
generate_pin,
2727
load_shared_key,
@@ -30,31 +30,31 @@
3030
initiate_pairing,
3131
respond_to_pairing,
3232
)
33-
from pyfuse.core.signing import (
33+
from away.core.signing import (
3434
sign_json,
3535
derive_key,
3636
verify_signature,
3737
compute_signature,
3838
verify_and_load_json,
3939
)
40-
from pyfuse.core.token import (
40+
from away.core.token import (
4141
load_token,
4242
save_token,
4343
clear_token,
4444
generate_token,
4545
resolve_signing_key,
4646
)
47-
from pyfuse.core.version import _VERSION
48-
from pyfuse.core.progress import ProgressInfo
49-
from pyfuse.core.progress import progress as progress
50-
from pyfuse.worker.remote import serve, connect, disconnect
51-
from pyfuse.worker.result import Result, ResultEnvelope
52-
from pyfuse.worker.worker import Worker
53-
from pyfuse.worker.worker import execute as execute
54-
from pyfuse.worker.sandbox import DockerSandbox
55-
from pyfuse.worker.schedule import ScheduleHandle
56-
from pyfuse.graph.decorator import trace
57-
from pyfuse.worker.backends.base import Backend
47+
from away.core.version import _VERSION
48+
from away.core.progress import ProgressInfo
49+
from away.core.progress import progress as progress
50+
from away.worker.remote import serve, connect, disconnect
51+
from away.worker.result import Result, ResultEnvelope
52+
from away.worker.worker import Worker
53+
from away.worker.worker import execute as execute
54+
from away.worker.sandbox import DockerSandbox
55+
from away.worker.schedule import ScheduleHandle
56+
from away.graph.decorator import trace
57+
from away.worker.backends.base import Backend
5858

5959

6060
def get_graph() -> Graph:
@@ -63,8 +63,8 @@ def get_graph() -> Graph:
6363
The returned :class:`Graph` has :meth:`~Graph.to_mermaid` for
6464
visualization::
6565
66-
print(pyfuse.get_graph().to_mermaid()) # full graph
67-
print(pyfuse.get_graph().to_mermaid(my_func)) # subgraph of my_func
66+
print(away.get_graph().to_mermaid()) # full graph
67+
print(away.get_graph().to_mermaid(my_func)) # subgraph of my_func
6868
"""
6969
return Graph.default()
7070

0 commit comments

Comments
 (0)