Commit Graph
644 Commits
Author SHA1 Message Date
can1357 70d48a43c9 Merge PR #3087: fix(natives): gate unix-only test helpers and imports with #[cfg(unix)] (@oldschoola) 2026-06-20 22:35:58 +02:00
Can BölükandGitHub c6126c75d9 Merge pull request #3083 from oldschoola/fix/pi-natives-clippy-dead-code
fix(natives): resolve pre-existing clippy dead-code warnings breaking CI
2026-06-20 22:33:51 +02:00
can1357 5a77619258 fix(natives): budget parallel grep stop on returned matches
The parallel streaming walker accumulated match_count toward the
first-page stop budget, but match_count can exceed the matches actually
returned (collected) by one whenever a file overflows its per-file cap.
With the production config (max_count=2000, max_count_per_file=21) that
over-count could quit the walk a few percent short of the requested
page. Budget on collected instead, matching run_sequential_grep and
aggregate_parallel_results.
2026-06-20 22:12:48 +02:00
roboomp 4575b75573 fix(natives): extended grep budget to parallel walker
Carried the streaming-grep match budget into the parallel visitor via a shared atomic counter so production callers (`maxCount: INTERNAL_TOTAL_CAP`) early-stop the walker instead of scanning the rest of the tree. Kept the sequential ordered path for small budgets where strict path ordering matters; the parallel path tolerates up to one extra file per worker in the tail, far better than walking the entire tree.\n\nFixes #2738
2026-06-20 12:10:59 +00:00
roboomp f03a553949 fix(natives): resolved grep merge conflict
Merged main into the PR branch and preserved the ordered small-budget grep cutoff on top of main's searched-file accounting and active-streaming worker fallback.\n\nFixes #2738
2026-06-20 12:04:26 +00:00
roboomp a1b65108a5 fix(natives): kept broad grep parallel
Limited the ordered streaming grep early-stop path to small first-page budgets so broad content searches keep the parallel walker. Added coverage that large budgets do not take the serial early-stop route.\n\nFixes #2738
2026-06-20 11:57:42 +00:00
can1357 62756efb8f chore: bump version to 16.1.7 2026-06-20 05:40:49 +02:00
can1357 73065ea431 chore: bump version to 16.1.6 2026-06-20 02:47:39 +02:00
oldschoola 824f435878 fix(natives): gate unix-only test helpers and imports with #[cfg(unix)]
The pi-natives test module had 8 warnings on Windows. Root cause: test
helpers (TempDirGuard, write_file, make_fifo, base_grep_config) and their
imports are only used by #[cfg(unix)] tests, so they appear as dead code
when compiled on Windows where those tests are excluded.

Fix: gate all unix-only test helpers, their imports, and the super::
imports they reference (classify_file_type, GrepConfig, GrepOutputMode,
grep_sync, crate::task, mpsc) with #[cfg(unix)] so they are excluded
from Windows compilation entirely. On Linux (CI), all helpers compile
and are used by the unix test suite.

Also removed genuinely unused import: Duration (from grep.rs test module
only — Duration in shell.rs is used by a non-cfg-gated test).

Verified: 0 warnings, 105 tests pass on Windows. Unix tests retain all
their helpers and imports.
2026-06-19 17:42:57 -07:00
oldschoola fe6375cbb2 fix(natives): resolve pre-existing clippy dead-code warnings
Gate platform-specific XDG functions (APP_NAME, xdg_state_logs,
default_agent_dir) and their tests with #[cfg(any(target_os = "linux",
target_os = "macos"))] so they are not flagged as dead code on Windows.
Suppress the false-positive missing_const_for_fn lint on Process::group_id
(#[napi] generates a non-const wrapper).

These 4 clippy warnings broke bun check (check:rs) and the CI
native_linux_x64 baseline job on every PR.
2026-06-19 17:01:46 -07:00
can1357 1a92b3f854 chore: bump version to 16.1.5 2026-06-19 22:27:50 +02:00
can1357 ee2b000bdc chore: bump version to 16.1.4 2026-06-19 20:45:56 +02:00
can1357 259bb004e1 chore: bump version to 16.1.3 2026-06-19 17:52:38 +02:00
can1357 db7ca77a8f chore: bump version to 16.1.2 2026-06-19 16:17:09 +02:00
can1357 492fe5e896 chore: bump version to 16.1.1 2026-06-19 09:03:07 +02:00
can1357 3d0b3d71af chore: bump version to 16.1.0 2026-06-19 08:08:44 +02:00
can1357 f7937c5e8d chore: bump version to 16.0.11 2026-06-19 04:59:59 +02:00
can1357 1df1349b99 ux: standardized elision markers
- Updated various truncation and overflow messages across `pi-shell` and `coding-agent` to use the consistent `[...N units elided...]` format.
- Improved clarity of elided output by explicitly stating the count and type of omitted information.
2026-06-19 04:42:06 +02:00
can1357 c224ef4df5 feat: standardized elision markers and improve transcript viewer robustness
- Standardized elision markers across all tool outputs and filters to use cohesive `[...N [type] elided...]`, `[...Nln elided...]`, and `[...xB elided...]` syntax.
- Updated documentation, prompts, and test expectations to reflect the unified elision format.
- Improved transcript viewer robustness by preventing content aliasing through path-inclusive signature hashing.
- Added logic to clear stale transcript content when associated session files are deleted, accompanied by verifying test cases.
2026-06-19 04:35:18 +02:00
can1357 8d671a71a7 refactor(pi-shell): improved test readability and formatting
- Updated line wrapping in module documentation and test blocks for consistent style.
- Adjusted variable assignment formatting in the segmented chain test to improve readability.
2026-06-19 03:35:53 +02:00
can1357 2e6e56711f fix: prevented shell command corruption in sequential chains
- Validated every stage of a pipeline against `simple_command_is_safe` instead of only the first stage to prevent improper segmentation of compound shell constructs.
- Guarded segment re-execution by verifying that each `Display`-reconstructed command parses back to the expected pipeline shape.
- Configured segmented-chain execution to fall back to an unsegmented, whole-command path whenever a reconstructed segment diverges from the original AST.
- Resolved a syntax error during command execution by preventing `Display` from stripping terminators from compound commands like `while` and `for` loops.
2026-06-19 02:39:44 +02:00
can1357 623ae8df35 chore: bump version to 16.0.10 2026-06-19 01:32:28 +02:00
can1357 20f8c3776f chore: bump version to 16.0.9 2026-06-18 23:01:31 +02:00
can1357 2023a6f674 chore: bump version to 16.0.8 2026-06-18 20:05:56 +02:00
can1357 f5ebab2b83 feat(utils): vendor mermaid rendering 2026-06-18 18:52:38 +02:00
can1357 93624f0239 chore: bump version to 16.0.7 2026-06-18 16:38:08 +02:00
can1357 667aee7ec6 chore: update changelogs 2026-06-18 16:37:45 +02:00
Tobias Linn 0142dd7e2c $ is not a valid identifier in fortran 2026-06-18 15:09:32 +02:00
Tobias Linn d19cd172d0 do not replace $ by µ for ast_grep, as its grammar allows $ 2026-06-18 14:11:12 +02:00
Tobias Linn ef8f6c0204 added fortran program summary test 2026-06-18 12:47:46 +02:00
Tobias Linn 9c970dfe60 removed older fortran extensions for fixed-form 2026-06-18 12:27:41 +02:00
Tobias Linn 98306f25a5 formatting 2026-06-18 12:10:12 +02:00
Tobias Linn 10f5d86143 feat(coding-agent): add support for Fortran language 2026-06-18 11:54:04 +02:00
can1357 159b8a1c63 chore: bump version to 16.0.6 2026-06-18 03:20:08 +02:00
can1357 78bc44a5ac feat(pi-natives): removed filesystem cache and implement sequential fallback for streaming grep
- Removed the `cache` option from `GrepOptions` and eliminated the internal directory cache path.
- Implemented `run_sequential_grep` as a single-threaded fallback when too many concurrent streaming searches are active.
- Restricted concurrent grep workers under heavy resource contention using a global `ACTIVE_STREAMING_GREPS` atomic counter.
- Cleaned up obsolete benchmark scenarios, typescript type definitions, and reference tests for cached grep searches.
- Removed the `cache` option from `GrepOptions` and internal caching mechanisms in `grep_sync`.
2026-06-18 02:29:39 +02:00
can1357 566999854a feat(pi-natives): returned total searched files count in grep results
- Implemented file tracking during search using an `AtomicU64` counter.
- Integrated the counter into parallel visitor structures to increment with each visited file.
- Updated the streaming grep function signature to return the cumulative count of searched files.
- Expanded the native test suite to verify accurate file counts and edge cases like empty search directories.
- Added a JavaScript unit test to validate that advise tool calls are summarized correctly by their note argument.
2026-06-18 02:06:43 +02:00
can1357 77e00a2886 feat(pi-natives): tracked searched files count in parallel grep status
- Added a `files_searched` atomic counter to `run_parallel_search` to track the total number of files processed.
- Increments the search counter during parallel execution immediately after a file is successfully read.
- Short-circuits and filters out file search results that yield zero matches.
2026-06-18 01:57:28 +02:00
can1357 2cd78dbf24 refactor(natives): configured searcher line numbers based on output mode
- Configured searcher line numbers based on whether the output mode is set to content.
- Updated `build_searcher` and `build_searcher_for_params` to accept and set the line number flag.
2026-06-18 01:57:23 +02:00
can1357 7e87709d22 chore: bump version to 16.0.5 2026-06-17 15:11:23 +02:00
can1357 94a813788f chore: bump version to 16.0.4 2026-06-17 09:44:33 +02:00
can1357 2ccbd0bbea fix: skipped oversized spans while continuing BFS summary unfolding
- Changed `select_folded_spans` to skip an unfold candidate that exceeded `unfold_limit` and continue processing the remaining BFS queue instead of breaking.
- Added a regression test in `summary.rs` proving a large `<style>` raw-text span no longer starves sibling HTML sections from unfolding.
- Updated the summary unfold-ceiling setting description to document that overflowed candidates stay folded while BFS continues.
2026-06-17 09:24:19 +02:00
can1357 8eeb707387 chore: bump version to 16.0.3 2026-06-17 01:58:36 +02:00
can1357 dc14689fc1 chore: bump version to 16.0.2 2026-06-16 15:33:47 +02:00
can1357 ce005fbb45 Merge PR #2693: feat(ast): add Emacs Lisp tree-sitter support
Add the tree-sitter-elisp grammar plus language wiring, highlight mapping, and .emacs/.el detection. Native side verified via cargo (pi-ast elisp tests + pi-natives alias test).
2026-06-16 14:52:39 +02:00
0xff26b9a8 d4b01d3a48 fix(tui): handle VS Code keypad digit input 2026-06-16 18:55:23 +08:00
roboomp 20d8f07da0 fix(natives): preserved ordered grep budget
Moved the streaming max-count shortcut onto the ordered walker so early exits preserve path-order first-page results. Counted emitted matches rather than raw per-file match totals for the stop budget.\n\nFixes #2738
2026-06-16 05:28:52 +00:00
roboomp c791361d04 fix(natives): stopped broad grep after match budget
Stopped streaming directory grep once content searches have collected the requested first page of matches instead of continuing to walk large trees until the timeout trips. Added native coverage for the streaming budget cutoff.\n\nFixes #2738
2026-06-16 05:00:36 +00:00
ryjm c2a14a0afc fix(ast): infer extensionless Emacs init files 2026-06-15 18:58:55 -07:00
ryjm 18f11f5bfc feat(ast): add Emacs Lisp tree-sitter support
Register tree-sitter-elisp in the shared AST language registry so
.el files infer the emacs-lisp grammar across blockRangeAt,
summarizeCode, astGrep/astEdit, and native aliases.

This fixes edit-tool block operations on top-level Emacs Lisp forms
instead of returning unsupported-language block errors.

- Add canonical emacs-lisp aliases and .el extension inference.
- Teach summaries to fold Lisp forms without grouping arbitrary lists.
- Map .el rendering and highlighting aliases through coding-agent/native.
- Cover defun, ERT, use-package, with-eval-after-load, pcase,
  summary, astMatch, astEdit, and edit-tool insertion paths.
- Document the language and update package changelogs.
2026-06-15 18:41:24 -07:00
can1357 e24f789de4 chore: bump version to 16.0.1 2026-06-15 21:30:30 +02:00