Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion coworker/connectors/adapters.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ async def connect(self) -> bool:
# Base-URL override so tests (and the FakeSlack harness) can redirect every Web API
# call — auth.test/users.info/conversations.info/chat.update AND Socket Mode's
# apps.connections.open, which the handler issues on this same client. Default is the
# real Slack API. See platform/docs/FAKE-SLACK-SPEC.md.
# real Slack API. See docs/FAKE-SLACK-SPEC.md.
base_url = os.environ.get("SLACK_API_URL", "https://slack.com/api/")
client = AsyncWebClient(token=self.bot_token, base_url=base_url)
self._app = AsyncApp(client=client)
Expand Down
2 changes: 1 addition & 1 deletion coworker/connectors/senders.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

def _slack_api_base() -> str:
"""Web API base URL. `SLACK_API_URL` (trailing slash) lets tests / the FakeSlack harness
redirect outbound sends to a local fake. See platform/docs/FAKE-SLACK-SPEC.md."""
redirect outbound sends to a local fake. See docs/FAKE-SLACK-SPEC.md."""
return os.environ.get("SLACK_API_URL", "https://slack.com/api/")


Expand Down
2 changes: 1 addition & 1 deletion coworker/personas/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
A persona is a manifest (YAML frontmatter + a markdown body that is the system prompt) that
composes vetted catalog capabilities, a family/workspace shape, and lifecycle metadata. The
built-in surfaces (Code, Cowork, Chat, Ops) are themselves manifests — the same format third
parties use. See `platform/docs/PERSONAS.md`.
parties use. See `docs/PERSONAS.md`.
"""

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion coworker/testing/fake_slack/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"""FakeSlack — a local, controllable Slack test double (Web API + Socket Mode).

See :mod:`coworker.testing.fake_slack.server` and ``platform/docs/FAKE-SLACK-SPEC.md``.
See :mod:`coworker.testing.fake_slack.server` and ``docs/FAKE-SLACK-SPEC.md``.
"""

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion coworker/testing/fake_slack/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Slack app console**. Built on Starlette + uvicorn (both already core deps) and served on an
ephemeral port via an in-process ``uvicorn.Server`` background task.

See ``platform/docs/FAKE-SLACK-SPEC.md``. The adapter is pointed at the fake via the
See ``docs/FAKE-SLACK-SPEC.md``. The adapter is pointed at the fake via the
``SLACK_API_URL`` base-URL override (env), which redirects every Web API call — including
Socket Mode's ``apps.connections.open``, so the fake decides the WebSocket URL.

Expand Down
16 changes: 8 additions & 8 deletions surfaces/gui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,23 @@ Same codebase runs in a browser (dev) and as the OpenWorker desktop app.

## First time: bootstrap the Python backend

A fresh checkout has no server to run — create the venv both flows below expect:
A fresh checkout has no server to run — create the venv both flows below expect
(run from the repo root):

```bash
bash platform/packaging/setup_dev_env.sh # → platform/.venv (server + this repo's aisuite)
bash packaging/setup_dev_env.sh # → .venv (server + this repo's aisuite)
```

## Run it (browser, two terminals)

1. **Start the server** (needs a model key, e.g. `OPENAI_API_KEY`, in the environment —
or add one later in the app's Settings):
or add one later in the app's Settings). From the repo root:
```bash
cd platform
./.venv/bin/openworker-server --cwd /path/to/your/project --port 8765
```
2. **Start the UI:**
```bash
cd platform/surfaces/gui
cd surfaces/gui
npm install # first time
npm run dev # → http://localhost:5173
```
Expand All @@ -35,11 +35,11 @@ Vite if the server is restarted.

The Tauri shell wraps the same UI and supervises the Python server itself — no separate
terminal. It needs the Rust toolchain (`rustup`) plus the venv from the bootstrap step;
in dev it finds the server at `platform/.venv/bin/openworker-server` automatically (a
packaged sidecar binary is only produced by the release scripts in `platform/packaging/`).
in dev it finds the server at `.venv/bin/openworker-server` automatically (a
packaged sidecar binary is only produced by the release scripts in `packaging/`).

```bash
cd platform/surfaces/gui
cd surfaces/gui
npm install # first time
npm run tauri dev # builds the shell, launches the window, starts the server
```
Expand Down
2 changes: 1 addition & 1 deletion surfaces/gui/src-tauri/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ fn launch_token() -> String {
/// (next to the app exe) on Windows.
/// 3. Legacy onefile slot: `openworker-server[.exe]` next to the app binary (pre-onedir
/// builds used Tauri externalBin).
/// 4. Dev fallback: the repo venv, relative to this crate (`src-tauri` → `platform/.venv`;
/// 4. Dev fallback: the repo venv, relative to this crate (`src-tauri` → `.venv`;
/// `bin/` on POSIX, `Scripts\` on Windows).
fn server_bin() -> PathBuf {
if let Ok(p) = std::env::var("COWORKER_SERVER_BIN") {
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
`fake_slack` boots the in-process FakeSlack harness on an ephemeral port and points the Slack
adapter at it via `SLACK_API_URL`, so the real `SlackAdapter` / `slack_bolt` stack runs
end-to-end with no network, tokens, or the Slack app console. See
`coworker.testing.fake_slack` and `platform/docs/FAKE-SLACK-SPEC.md`.
`coworker.testing.fake_slack` and `docs/FAKE-SLACK-SPEC.md`.
"""

from __future__ import annotations
Expand Down
2 changes: 1 addition & 1 deletion tests/test_fake_slack.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""FakeSlack acceptance tests — the real SlackAdapter / slack_bolt stack driven against the
in-process fake (no network). Mirrors the acceptance list in `platform/docs/FAKE-SLACK-SPEC.md`.
in-process fake (no network). Mirrors the acceptance list in `docs/FAKE-SLACK-SPEC.md`.

These are hermetic (no real Slack) and run in CI — not marked `integration`. The `fake_slack`
fixture (see conftest.py) starts the server and sets `SLACK_API_URL`.
Expand Down