Commit Graph

90 Commits

Author SHA1 Message Date
BFlat c89f6603dd adb_app_show says a missing package isn't installed (#258)
`adb_app_show` treated `dumpsys package <name>` output as describing the package if it merely contained the name. Android's answer for a missing package, `Unable to find package: <name>`, contains the name, so the tool returned successful evidence with no fields and complete coverage.

It now requires that package's own `Package [<name>]` block and otherwise returns the existing `NotFound` error with the "List installed packages with adb_apps_list." remediation.

**Verified:** a unit test with Android's missing-package reply, another package's block and an installed package; `cargo test -p craft-anything-engine adb`, clippy, fmt.

**Not verified:** a run against a real device.

Fixes #235
2026-11-02 13:43:22 +07:00
BFlat 27d93b9ae3 A capture's timeout stops every process in the group, not just the leader (#246)
On a timeout with a grace period, a capture sent SIGTERM to the group, then waited only for the leader. When the leader exited, it skipped the SIGKILL, so a helper in the group that ignores SIGTERM kept running after the capture returned (reported as `still_running` / `incomplete`).

Now the grace period waits for the whole group to be gone, reaping the leader as it goes so a zombie doesn't count. Whatever is left afterwards gets SIGKILL. `settle` uses the same group check.

**Verified:**
- A new Linux/macOS test with the reporter's helper (ignores TERM and HUP, outlives the leader): the capture must settle, verify cleanup and report SIGKILL.
- `cargo clippy -p craft-anything-platform --all-targets --target x86_64-unknown-linux-gnu -D warnings`, fmt.

**Not verified locally:** this machine is Windows without WSL, so the new test first runs in CI (Ubuntu). macOS isn't run; it uses the same code.

Fixes #230
2026-11-02 13:39:04 +07:00
BFlat 55816983e8 First-run steps scroll when the window is too short, so Continue stays reachable (#243)
At the smallest window the app allows (760×520), the first-run "What brings you here?" step was taller than the window and had nothing to scroll, so its Continue button sat below the window, out of reach.

The first-run steps now sit in a scroll area that stops above the footer (Back and the step counter). When a step fits, nothing changes; when it doesn't, it scrolls.

**Verified:**
- A new smoke test at 760×520 scrolls Continue into view above the footer and clicks it through to the last step. Without the fix, Continue is drawn at y=646 in a 520-high window and the test fails.
- `cargo test -p craft-anything-ui-egui` (all suites), clippy, fmt.
- Rendered the first-run screens at the default size (unchanged, no scroll bar) and at 760×520 (scrolls, ends above the footer).

Fixes #231
2026-11-02 13:32:55 +07:00
GGWA 35d76945ca ELF files with no section headers show their dynamic symbols and functions (#233)
ELF files whose section headers were removed (common in NAS and router firmware) now show their functions, imports and exports. The dynamic symbol table is found through PT_DYNAMIC (DT_SYMTAB/DT_STRTAB, counted from DT_HASH, then DT_GNU_HASH, then an estimate with a warning), shared with the Flutter reader. The prologue scan walks executable segments when there are no sections.

Fixes #223
2026-11-02 13:26:37 +07:00
BFlat 1207715afd Pseudo-Java keeps the statements before a try (#242)
The pseudo-Java for a method with one try/catch rendered the protected region, the handler and what follows, but never the statements before the `try`. So `v0 = 7; try { v1 = 2; } catch (RuntimeException e) {} return v0;` came out without `v0 = 7;`.

- Those statements are now rendered first. A branch from them into the try region falls back to a labelled `goto`, as elsewhere, so the method is no longer marked fully structured.
- The single-handler wrap is now refused when anything sits between the try's closing `goto` and the handler. That code would have been dropped the same way; such methods now get the plain rendering with the "exception handler(s) in the table" note.

**Verified:** a test with the reporter's 152-byte class (it fails without the fix); `cargo test -p craft-anything-analysis` (79), the engine's Java tool tests (9), clippy, fmt.

**Not checked:** `cargo xtask wasm`. The change is pure logic inside an existing function.

Fixes #232
2026-11-02 13:26:28 +07:00
BFlat 07fe869dc4 A same-size rewrite of an unhashed file reads as unknown, not unchanged (#241)
A runtime capture compared a file's size, type and hash. When the file was over the hashing budget (or couldn't be read), neither snapshot had a hash, so a rewrite at the same size was reported as `unchanged`. Now:

- such a file is `unknown`;
- a file is `modified` only when its size or type changed, or both hashes exist and differ;
- a symlink pointed somewhere else with a target of the same length is `modified` (only the target's length was compared before).

**Verified:** a new unit test of `effects` (unhashed on either side, equal and different hashes, a size change, symlink retargets); `cargo test -p craft-anything-platform` (47 passed), clippy, fmt. The test runs on every OS, unlike the shell-based capture tests.

**Not verified:** a live run of the issue's capture probe on macOS.

Fixes #229
2026-11-02 13:24:22 +07:00
vietanh210304 233556ed1d Hermes Agent builds and chats through its own adapter, and over ACP (#16)
Hermes Agent gets its own adapter: it runs as `hermes [-m <model>] [args] -z <prompt>`, never falls back to a plain `hermes <prompt>` (which opens its interactive session), and can run over ACP (`hermes acp`) when ACP is turned on.
2026-11-02 13:17:02 +07:00
muraa-p b36007cf8b A plain HTML and CSS request builds a static site instead of a Rust app (#225)
A request for a plain HTML and CSS site ("no frameworks", "no build step", "static html") now picks a Plain HTML and CSS stack: index.html and a stylesheet in app/, with nothing to build. Before, the request named no stack and the builder chose Rust + egui.

Fixes #161
2026-11-02 13:16:51 +07:00
Brandon Thomas da83b81be2 A build stops with a plain message when craft-anything-cli is missing (#226)
A local build by Claude Code, Codex or an ACP agent now checks that craft-anything-cli starts before studying or starting the agent. When it is missing or won't start, the build stops with a plain message and what to do, instead of Claude Code's "MCP tool not found" error. A check that times out lets the build go ahead, and stopping the build ends the check.

Refs #91, #64, #113.
2026-11-02 13:16:39 +07:00
BFlat 4419c674cf "It's done" keeps a build as it is and stops offering to carry on (#221)
A paused, stopped or failed build only offered Continue or Try again; there was no way to say "enough now". project_build_finish marks the project Ready and adds a Done step to its conversation, keeping everything; the project screen shows It's done beside Continue and Try again when nothing is running.

Fixes #210
2026-11-02 11:51:58 +07:00
BFlat fe6a8ad98c From the CLI, a capture with no open site says each command starts its own browser (#213)
web_site_open keeps its browser for one session, and each CLI command is a session of its own that closes its browser when it ends. From the CLI, a capture with no open site now says so, and to run the steps together in an MCP client, the app or rebuild. Documented in tool-status.

Fixes #153
2026-11-02 11:31:28 +07:00
GGWA fff225d319 The Windows pipe gap in project_play is noted in its tool help and kept as an ignored test (#212)
project_play's help says that on Windows a started program inherits the caller's output pipe (#207), and the reproducing test is kept in platform as an ignored test.
2026-11-02 11:28:57 +07:00
BFlat 4756c15642 Captured colours are the page's CSS values, not a canvas read that drifted by one (#211)
Every computed colour was painted on a 1x1 canvas and read back; Brave adds noise to canvas reads, so colours came back one unit off per channel (#F5F2EC as #f4f2ed). Computed rgb()/rgba() values are now read as numbers, and only other notations go through the canvas.

Fixes #154
2026-11-02 11:23:32 +07:00
NetterSilver 32b80be890 A 10-byte LEB128 value whose bits don't fit is rejected instead of truncated (#208)
checked_shl only rejects shift amounts of 64 or more, so payload bits shifted out of the u64 on the tenth byte were dropped; uleb128 now returns None when bits would be lost, and u64::MAX still decodes.
2026-11-02 10:40:37 +07:00
GGWA 648fbd7bde A Mach-O method list at the end of the address space is read without overflowing (#205)
Each method entry's address and its fields' addresses are computed with checked arithmetic, so a method list near the end of the address space ends the list instead of panicking (debug) or reading a wrapped address (release).
2026-11-02 10:09:52 +07:00
GGWA fa7f1a114e An A32 doubleword load or store into r15 decodes as invalid instead of stopping the ARM analysis (#204)
An A32 LDRD/STRD with Rt=15 (e.g. 0xc0c7fef3) made the decoder library panic on the nonexistent r16; such a word now decodes as no instruction, before the library sees it.
2026-11-02 10:07:46 +07:00
BFlat 145d65c96c Codex is never run as plain text, which opened its interactive mode (#200)
When the check of codex exec --help didn't find --json, the run fell back to the plain adapter, codex <prompt>, which is Codex's interactive TUI and fails with "stdin is not a terminal". An adapter can now say its plain form doesn't work; Codex keeps its own adapter and the run says the check couldn't confirm the flag.

Fixes #199
2026-11-02 08:57:54 +07:00
one-bit 1dcb46b2f8 Unreal Engine installations and their bundled Clang are found on Linux (#191)
Reads Linux registrations from ~/.config/Epic/UnrealEngine/Install.ini, honours a valid UE_ROOT, takes the version from Build.version, and counts the selected engine's own bundled Clang as its C++ tools.
2026-11-02 07:11:30 +07:00
GGWA 4448b24065 A pill corner made with calc(infinity * 1px) is captured as 9999px (#189)
Chrome reports Tailwind v4's rounded-full as its largest length, 3.35544e+07px; the capture now records any corner above 9999px as 9999px and keeps the other corners.

Fixes #155
2026-11-02 07:08:41 +07:00
Firefly e0f97a2626 The fallback-order test covers a font it doesn't recognise (#187)
Adds an unknown family to the fallback-order test, so FallbackRank::Other is checked and sits between sans and serif faces.
2026-11-02 06:44:38 +07:00
BFlat 2022642554 Setup and the doctor read a client's other names from one table (#184)
agy as another name for antigravity was written out by hand in both; Client::is now matches an id with dashes or underscores, or an alias.
2026-11-02 06:10:56 +07:00
BFlat 34d0d654ba Clean room captures leave out class names and query strings (#183)
A visitor's view of a site no longer keeps the page's class names (outline items and unnamed-control examples) or the query strings and fragments on image and link addresses, which can carry deployment ids and tokens.

Fixes #156
2026-11-02 06:08:01 +07:00
X-EON d0c341739b Antigravity (agy) works as an agent program, in setup and the doctor (#89)
Adds an Antigravity adapter (stream-json output, resume by conversation, builder permissions) and lets setup and the doctor connect and check it under `antigravity` or `agy`.
2026-11-02 05:59:23 +07:00
BFlat 7776b97d2b A question answered outside a build stays in the project's conversation (#180)
Callers take the question before answering, and record_answer adds it with its answer when the saved conversation doesn't have it, once. Fixes #176.
2026-11-02 05:35:28 +07:00
BFlat 706f250c1c A failed build check says where it looked, not app/ for an app edited in place (#178)
The build check's messages name where the app is (Workspace::app_place): app/, or the project folder for an app edited in place. Fixes #174.
2026-11-02 05:26:27 +07:00
BFlat 3a60c04c27 Browser evidence records Clean room when the run is in Clean room (#177)
Results read through a browser record the run's mode in environment.clean_room instead of always false. Fixes #157.
2026-11-02 05:23:44 +07:00
BFlat e4a4cf1f4a A website capture refuses the browser's error page (#171)
web_site_capture checks where the page is first and refuses, without making the output folder, when the browser is on its own error page or a blank one after a failed open. Fixes #158.
2026-11-02 04:54:03 +07:00
BFlat b9905c63a4 An out-of-date Claude Code says so, and how to update it (#169)
Claude Code's "does not support this model" error says Claude Code is too old, with the fix (claude update for the command-line tool, or another model in Settings → AI), and isn't retried. Fixes #165.
2026-11-02 04:41:07 +07:00
BFlat c94483d6a1 A full-page website capture scrolls through the page first (#168)
Before each width's full-page screenshot the page is scrolled through, lazy images are loaded and waited on (5 s at most), and it goes back to the top, so scroll-revealed sections and lazy images are in the picture. Fixes #160.
2026-11-02 04:37:41 +07:00
Ole Bohmbach ca355ea19d Give every Settings tab the same width, with air before the scroll bar (#151)
The Settings scroll area no longer shrinks to each tab's content, so every tab has the same width and the scroll bar stays in one place; settings keep 14 points clear of it.
2026-11-02 04:16:17 +07:00
BFlat aae724f14b A rate-limited AI service is waited for as long as it asks (#148)
The builder reads the wait a busy or rate-limited service asked for (at most 15 minutes), says so plainly, and tries again then, instead of a fixed 30/60/90 s with the raw error. For #142.
2026-11-02 03:24:04 +07:00
Ole Bohmbach 3f8690a923 Find the Godot editor that the store installs on macOS (#141)
The macOS zip unpacks as Godot.app; it's renamed to Godot_v<version>.app so the engine store finds it, moving a previous install aside and restoring it if the rename fails.
2026-11-02 03:19:18 +07:00
BFlat e4d43abe14 Choose the model an AI uses in Settings → AI (#145)
Settings → AI shows each AI's model with Change…, listing the API's own models or Claude's models for Claude Code; craft-anything-cli ai model <name> [model] lists or sets it. Fixes #123 and #127.
2026-11-02 03:06:40 +07:00
BFlat 69c0b8c9be Find coding agents npm installed under a custom prefix (#139)
npm's global prefix, from NPM_CONFIG_PREFIX or prefix= in ~/.npmrc (its bin folder outside Windows), is searched after PATH with the other usual folders, without running npm. Fixes #132.
2026-11-02 02:37:17 +07:00
BFlat 8ea06bb6fb Add an AI by its address in Settings → AI (#137)
Settings → AI gets an Add an AI by its address form; AiHub::add_server asks the server for its models before adding it and picks one that can chat when none is named; ai add --kind openai_compatible --base-url without --model does the same. Fixes #54, #98 and #128.
2026-11-02 02:32:11 +07:00
BFlat 8c3532d94c Test that a stopped stand-in frees its port where the server is, without racing other tests (#136)
The engine test no longer connects to the stopped stand-in's port, which another parallel test could be handed; platform::standin_server tests that dropping a server frees its port, trying it for a moment.
2026-11-02 02:09:00 +07:00
BFlat 12d7bc14d6 Look for AI picks a model that can chat, not an embedding model (#134)
Detection picks the first listed model that isn't named for embedding, ranking or speech, and falls back to the first only when that's all there is. Fixes the cause of #127.
2026-11-02 02:08:49 +07:00
Agapenor 481361563b A Flutter library with a header table at the very end of the address range is read safely (#131)
Elf::parse in formats/src/dart.rs skips a program or section header entry that starts past the end of the file, so its field offsets can't overflow.
2026-11-02 01:46:48 +07:00
Firefly 4c0eb23563 Name the font fallback order, and test the order itself (#129)
The fallback font order uses a named FallbackRank, and the test checks the order sans_first produces.
2026-11-02 01:42:58 +07:00
BFlat 01994f0622 A program run in a console on Windows doesn't lose what it wrote on a busy computer (#126)
console_text waits for the program's output to arrive and settle before closing the console, waits up to 15 s for it, and says so instead of returning an empty screen.
2026-11-02 01:11:03 +07:00
Firefly 376e8efcbd Draw CJK interface text in a sans font, not a mincho (#125)
Fallback fonts are ordered sans first (BIZ UDPGothic, then Noto Sans CJK, then other sans faces), with mincho and serif faces last, so Japanese and Chinese interface text isn't set like a book page.
2026-11-02 01:10:52 +07:00
BFlat 9d3ea967fb Translate the agent program setting into Chinese (#122)
Both Chinese catalogs get the five strings #117 added, so cargo xtask i18n-coverage passes again on main; pitfalls.md notes the case.
2026-11-02 00:51:01 +07:00
BFlat 9c93f3a8ba Find coding agents in OpenCode's install folder and under nvm (#120)
~/.opencode/bin, ~/bin and the bin folders of nvm's Node versions (newest first) are searched after PATH with the other usual folders, so a desktop-started app finds OpenCode from its own installer and agents npm installed under nvm.
2026-11-02 00:39:38 +07:00
BFlat 187fe5e000 Godot installs on macOS: its program may be bigger than other engines' files (#118)
The per-file unpack limit is passed per download: 256 MB for pinned tools as before, 1 GiB for Godot, whose download is checked against its official SHA-512 list first. Fixes #100.
2026-11-02 00:35:08 +07:00
才倾梦华V d55523e6cd Add Simplified and Traditional Chinese UI translations (R2.9) (#115)
Adds Simplified and Traditional Chinese UI catalogs, picks the UI language from the system when Language is System, makes prices and a few labels translatable, recognises Chinese words for games and websites in requests, and adds cargo xtask i18n-coverage and docs/localization.md.
2026-11-02 00:34:31 +07:00
BFlat 1a199ec531 Choose an agent app's program in Settings → AI (#117)
Each local agent app in Settings → AI shows which program runs it, with Choose… and Find it automatically; craft-anything-cli ai program <name> [path] does the same. The not-installed errors point there instead of a setting that didn't exist.
2026-11-02 00:32:39 +07:00
WadahBadawi fdcb8cb0f6 Fall back to BM_CLICK for off-screen Win32 buttons and check boxes in UI walkthroughs (#77)
When UI Automation's button or check box proxy fails (it uses SendInput, which needs an interactive desktop), the walkthrough posts BM_CLICK to the control's window instead. PostMessage, so a click that opens a dialog doesn't block the walkthrough; only for buttons and check boxes.
2026-11-01 23:56:44 +07:00
BFlat ca706dc980 Look for AI offers local servers already set up in OpenCode (#111)
Look for AI reads provider baseURLs from OpenCode's settings and probes those on this computer or its network, so LM Studio on another port or a server on another machine is offered. The JSONC reader moves from setup to formats so ai can use it. Fixes #83.
2026-11-01 23:56:28 +07:00
BFlat 484f22e4b7 A rebuilt stand-in waits for its predecessor's port instead of failing (#109)
Taking over a replaced stand-in's port tries a busy port again for up to two seconds, so a restart no longer fails now and then with Address already in use.
2026-11-01 23:42:45 +07:00
BFlat 52b10bc5ba The Settings window keeps its width on every tab (#108)
The Settings tab column takes exactly what's left of the window with room for the scroll bar, and a path field leaves room for its button, so the Engines tab no longer widens the window. Fixes #68.
2026-11-01 23:37:35 +07:00