Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
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: 2 additions & 0 deletions .github/workflows/desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Test history browser startup recovery
run: python -m unittest discover -s test -p history_worker_test.py
- run: npm ci
- run: npm run package
- name: Install the Windows download
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Documentation
on:
push:
branches: [main]
paths: ['website/**', 'docs/screenshots/**', 'assets/vapora.svg', 'assets/vapora.ico', '.github/workflows/docs.yml']
paths: ['package.json', 'docs/releases/**', 'website/**', 'docs/screenshots/**', 'assets/vapora.svg', 'assets/vapora.ico', '.github/workflows/docs.yml']
pull_request:
paths: ['website/**', 'docs/screenshots/**', 'assets/vapora.svg', 'assets/vapora.ico', '.github/workflows/docs.yml']
paths: ['package.json', 'docs/releases/**', 'website/**', 'docs/screenshots/**', 'assets/vapora.svg', 'assets/vapora.ico', '.github/workflows/docs.yml']
workflow_dispatch:
permissions:
contents: read
Expand Down
24 changes: 12 additions & 12 deletions docs/release-runbook.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This runbook covers desktop downloads and source archives on GitHub. The package

## release candidate

The candidate is **2.2.5**, with [release notes](releases/2.2.5.md). It improves graph image quality, hover stability, contextual help and Results navigation, and compacts the History toolbar. **2.2.4** remains the published release until this candidate passes review and native package checks. **2.2.1** was withdrawn; its tag remains fixed. Do not reuse either tag.
The candidate is **2.2.6**, with [release notes](releases/2.2.6.md). It fixes settings races, incomplete Steam coverage, history export/import and packaged history startup. **2.2.5** remains the published release until this candidate passes review and native package checks. **2.2.1** was withdrawn; its tag remains fixed. Do not reuse either tag.

Use the existing tag convention without a `v` prefix. Desktop installers start at `2.0.1`; `2.0.0` contains source archives only, and `1.0.2` contains the legacy Python executable. Publish only after authorization, resolved review findings and green CI on the pinned main commit.

Expand All @@ -27,8 +27,8 @@ Use the existing tag convention without a `v` prefix. Desktop installers start a
5. Confirm that the intended tag does not already exist locally or remotely. Never move an existing release tag.

```sh
git tag --list 2.2.5
git ls-remote --tags origin refs/tags/2.2.5
git tag --list 2.2.6
git ls-remote --tags origin refs/tags/2.2.6
gh release list --repo Microck/vapora
```

Expand All @@ -43,8 +43,8 @@ For a committed candidate, create an archive from its exact commit:
```sh
VAPORA_RELEASE_COMMIT=REPLACE_WITH_REVIEWED_MAIN_COMMIT

git archive --format=tar.gz --prefix=vapora-2.2.5/ \
--output=/tmp/vapora-2.2.5-source.tar.gz "$VAPORA_RELEASE_COMMIT"
git archive --format=tar.gz --prefix=vapora-2.2.6/ \
--output=/tmp/vapora-2.2.6-source.tar.gz "$VAPORA_RELEASE_COMMIT"
```

Extract it into a fresh directory and run:
Expand Down Expand Up @@ -81,21 +81,21 @@ Proceed only after explicit approval of the tag and notes, all findings are reso
4. Create an annotated tag at the pinned commit. Git is used here because Jujutsu does not create annotated tags:

```sh
git -c user.name=Microck -c [email protected] tag -a 2.2.5 \
"$VAPORA_RELEASE_COMMIT" -F docs/releases/2.2.5.md
git push origin refs/tags/2.2.5
git -c user.name=Microck -c [email protected] tag -a 2.2.6 \
"$VAPORA_RELEASE_COMMIT" -F docs/releases/2.2.6.md
git push origin refs/tags/2.2.6
```

5. Wait for core CI and Desktop packages CI triggered by the new tag to pass on the pinned commit. Download that tag run's verified artifacts into `/tmp/vapora-desktop-downloads`. Compute `SHA256SUMS.txt` from the exact EXE, AppImage and DMG bytes, using their basenames. Confirm there are four tested downloads: Windows x64 installer and portable EXEs, Linux x64 AppImage, and macOS ARM64 DMG. Publish a normal GitHub release with those files attached from the start:

```sh
gh release create 2.2.5 \
gh release create 2.2.6 \
/tmp/vapora-desktop-downloads/*/*.exe \
/tmp/vapora-desktop-downloads/*/*.AppImage \
/tmp/vapora-desktop-downloads/*/*.dmg \
/tmp/vapora-desktop-downloads/SHA256SUMS.txt \
--repo Microck/vapora --verify-tag \
--title 'vapora 2.2.5' --notes-file docs/releases/2.2.5.md --latest
--title 'vapora 2.2.6' --notes-file docs/releases/2.2.6.md --latest
```

6. GitHub also provides the source ZIP and tar.gz. Do not publish an empty source-only release while waiting for desktop builds. Do not attach the legacy executable, replace existing public assets with `--clobber`, publish to npm or mark the release as a prerelease.
Expand All @@ -105,9 +105,9 @@ Proceed only after explicit approval of the tag and notes, all findings are reso
1. Confirm the release is published, not a draft, and points to the intended tag:

```sh
gh release view 2.2.5 --repo Microck/vapora \
gh release view 2.2.6 --repo Microck/vapora \
--json url,tagName,isDraft,isPrerelease,publishedAt,assets
git ls-remote --tags origin refs/tags/2.2.5 'refs/tags/2.2.5^{}'
git ls-remote --tags origin refs/tags/2.2.6 'refs/tags/2.2.6^{}'
```

2. Verify the annotated tag's peeled commit equals `VAPORA_RELEASE_COMMIT`.
Expand Down
15 changes: 15 additions & 0 deletions docs/releases/2.2.6.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# vapora 2.2.6

This patch release fixes issues found during automated and hands-on QA.

- Exported history reports can be imported again. Original captures are retained, repeated imports are deduplicated, and rankings are recomputed from validated observations rather than trusting exported scores. Empty and cross-account reports are rejected.
- Cancelled or superseded settings loads no longer overwrite newer edits or close a reopened dialog. Explicit profile selection takes precedence over startup defaults, and stale estimates are invalidated.
- A damaged optional default profile now produces a recoverable diagnostic instead of leaving a healthy app marked disconnected. The original file is preserved.
- Incomplete Steam groups and games responses remain unavailable rather than appearing as public empty lists. Partial observed game IDs are retained without claiming complete coverage.
- The packaged history helper recovers when Chromium starts without an initial page, using a bounded five-second fallback. Other startup errors still propagate.
- CLI commands reject extra operands before storage or network side effects. Installation examples and documentation now follow the current app version.
- The documentation build uses patched Next.js 16.4.1. The published docs remain a static export without a Next.js server or image-optimization endpoint.

Native package tests use disposable local Steam and history fixtures. Fixture tests do not establish live-provider access or production-account behavior. History imports retain the documented 2 MB browser limit.

Windows downloads include an installer and a portable EXE. The portable app keeps data in `Vapora-data` beside the EXE and needs about 1 GB free in Windows TEMP, plus space for scan data. Move the EXE and data folder together. Downloads are unsigned and not notarized; verify them against `SHA256SUMS.txt`.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vapora",
"version": "2.2.5",
"version": "2.2.6",
"private": true,
"description": "Explore public Steam friend networks",
"type": "module",
Expand Down
12 changes: 11 additions & 1 deletion scripts/history-worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import sys

from pydoll import Chrome, ChromiumOptions
from pydoll.exceptions import NoValidTabFound

USER_AGENT = "OpenAI File Downloader, XaiImageApiFetch/1.0"
logging.basicConfig(level=logging.CRITICAL)
Expand All @@ -26,6 +27,15 @@ async def evaluate(tab, script):
return response["result"]["result"]["value"]


async def start_tab(browser):
try:
return await browser.start()
except NoValidTabFound:
# Chromium may answer CDP before its initial page target exists. The
# process is already running; create a blank tab, not another browser.
return await asyncio.wait_for(browser.new_tab(), 5)


async def serve():
browser_path, profile_path, account, origin, sandbox = sys.argv[1:]
if not re.fullmatch(r"[0-9]{17}", account) or not 76561197960265728 < int(account) <= 76561202255233023:
Expand Down Expand Up @@ -54,7 +64,7 @@ async def serve():
if sandbox == "disabled":
options.add_argument("--no-sandbox")
async with Chrome(options=options) as browser:
tab = await browser.start()
tab = await start_tab(browser)
async def navigate():
async with tab.expect_cloudflare_turnstile(time_to_wait_captcha=15):
await tab.go_to(f"{origin}/id/{account}", timeout=30)
Expand Down
7 changes: 7 additions & 0 deletions src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,13 @@ export async function main(args = process.argv.slice(2)) {
if (["scan", "estimate"].includes(command)) argument = await readline.question("Steam profile URL or ID: ");
} finally { readline.close(); }
}
const commands = ["serve", "recent", "profiles", "scan", "estimate", "resume", "analyze", "profile-save", "history"];
if (!commands.includes(command)) throw new InputError({ message: `Unknown command: ${command}. Run --help.` });
const takesArgument = !["serve", "recent", "profiles"].includes(command);
if (parsed.positionals.length > (takesArgument ? 2 : 1)) {
throw new InputError({ message: `${command} accepts ${takesArgument ? "exactly one argument" : "no arguments"}. Run --help.` });
}
if (takesArgument && !argument) throw new InputError({ message: `${command} requires ${command === "history" ? "a file" : command === "resume" || command === "analyze" ? "a run ID" : "a target or profile name"}. Run --help.` });
const root = parsed.values.root ?? process.cwd();
const key = Redacted.value(await Effect.runPromise(Config.Redacted("STEAM_API_KEY").pipe(Config.withDefault(Redacted.make("")))));
if (command === "serve") {
Expand Down
2 changes: 1 addition & 1 deletion src/history-browser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ async function connect(id: SteamId, root: string, origin: string, sandbox: strin
return Schema.decodeUnknownSync(Provider.Response)(await response);
}, catch: (error) => error instanceof InputError ? error : new InputError({ message: "History's browser response could not be read. Retry the capture." }),
}));
const ready = receive(0, 95000);
const ready = receive(0, 100000);
return { request, close, ready };
}

Expand Down
9 changes: 9 additions & 0 deletions src/history.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,15 @@ export const parse = Effect.fn("History.parse")(function* (contents: string) {
const whole = Schema.decodeUnknownResult(json)(contents.trim());
if (whole._tag === "Success") lines = [whole.success];
else lines = contents.split(/\r?\n/).filter((line) => line.trim()).map((line) => Schema.decodeUnknownSync(json)(line.trim()));
const exported = lines.length === 1 ? object(lines[0]) : null;
if (exported && "sources" in exported && "profile" in exported) {
const report = Schema.decodeUnknownSync(HistoryReport)(exported);
if (!report.sources.length || report.sources.some((source) => !source.snapshots.length)) {
throw new InputError({ message: "The exported history report must retain its original snapshots." });
}
// Recompute derived rankings from validated observations, not exported scores.
return { sources: report.sources } satisfies Bundle;
}
const document = lines.length === 1 && object(lines[0])?.type === "SteamHistoryCapture"
? Schema.decodeUnknownSync(Document)(lines[0]) : null;
if (document) return { sources: [{ provider: "SteamHistory", capturedAt: document.capturedAt, contents,
Expand Down
11 changes: 8 additions & 3 deletions src/steam.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,16 +103,21 @@ export const layer = (options: Options) => Layer.effect(Service, Effect.gen(func
return yield* unavailable(get("/ISteamUser/GetUserGroupList/v1/", { steamid: id }, Schema.Struct({ response: Schema.Struct({
success: Schema.optionalKey(Schema.Boolean), groups: Schema.optionalKey(Schema.Array(Schema.Struct({ gid: Schema.String }))),
}) })).pipe(Effect.map((r) => ({
status: r.response.success === false ? "unavailable" : "public", values: (r.response.groups ?? []).map((g) => g.gid),
status: r.response.success === false || r.response.groups === undefined ? "unavailable" : "public",
values: r.response.success === false ? [] : [...new Set((r.response.groups ?? []).map((g) => g.gid))],
} satisfies Observation<string>)), Effect.catchIf((error) => error.status === 403, () => Effect.sync(() => {
groupAccessDenied = true;
return { status: "unavailable", values: [] } satisfies Observation<string>;
}))));
}),
games: Effect.fn("Steam.games")((id: SteamId) => unavailable(get("/IPlayerService/GetOwnedGames/v1/", {
input_json: JSON.stringify({ steamid: id, include_appinfo: false, include_played_free_games: true }),
}, Schema.Struct({ response: Schema.Struct({ game_count: Schema.optionalKey(Schema.Number), games: Schema.optionalKey(Schema.Array(Schema.Struct({ appid: AppId }))) }) })).pipe(
Effect.map((r) => ({ status: r.response.game_count === undefined ? "private" : "public", values: (r.response.games ?? []).map((g) => g.appid) } satisfies Observation<number>)),
}, Schema.Struct({ response: Schema.Struct({ game_count: Schema.optionalKey(Schema.Number.check(Schema.isInt(), Schema.isGreaterThanOrEqualTo(0))), games: Schema.optionalKey(Schema.Array(Schema.Struct({ appid: AppId }))) }) })).pipe(
Effect.map((r) => {
const values = [...new Set((r.response.games ?? []).map((g) => g.appid))];
return { status: r.response.game_count === undefined ? values.length > 0 ? "unavailable" : "private"
: values.length === r.response.game_count ? "public" : "unavailable", values } satisfies Observation<number>;
}),
))),
});
})).pipe(Layer.provide(FetchHttpClient.layer));
Loading
Loading