Commit Graph

9 Commits

Author SHA1 Message Date
can1357 89e6479661 refactor: migrated environment variable access from process.env to Bun.env across 71 files
- Migrated all environment variable access from Node.js `process.env` to Bun runtime `Bun.env` API across the entire codebase.
- Updated 71 files including source code, tests, documentation, and configuration to use Bun's native environment variable API.
- Added comprehensive environment variables documentation in `packages/coding-agent/docs/environment-variables.md` covering 100+ environment variables organized by category.
- Updated CHANGELOG entries to reflect migration from `process.env` to `Bun.env` and environment variable prefix changes (PI_* vs OMP_*).
- Maintained identical behavior and logic across all changes - only the environment variable access method was updated.
2026-02-05 04:51:18 +01:00
can1357 2c34b641cd revert "feat(coding-agent): added Grafana Pyroscope continuous profiling integration"
This reverts commit 1b81e820bf.
2026-02-05 02:38:33 +01:00
can1357 1b81e820bf feat(coding-agent): added Grafana Pyroscope continuous profiling integration
- Added Grafana Pyroscope continuous profiling integration for CPU and heap profiling.
- Added seven new Pyroscope configuration settings: enabled, serverAddress, appName, basicAuthUser, basicAuthPassword, tenantID, and flushIntervalMs.
- Added support for Pyroscope configuration via environment variables: PYROSCOPE_URL, PYROSCOPE_APP_NAME, PYROSCOPE_BASIC_AUTH_USER, PYROSCOPE_BASIC_AUTH_PASSWORD, PYROSCOPE_TENANT_ID, and PYROSCOPE_FLUSH_INTERVAL_MS.
- Integrated Pyroscope initialization and shutdown into the main application lifecycle with automatic profiling start/stop.
- Added @pyroscope/nodejs dependency for continuous profiling capabilities.
2026-02-05 02:17:35 +01:00
can1357 7e64c4b6d8 feat(natives): exported getWorkProfile function and WorkProfile type from main package index
- Exported getWorkProfile function and WorkProfile type from main package index for work profiling capabilities.
- Updated coding-agent debug module imports to use new main package exports instead of subpath imports.
2026-02-02 13:39:00 +01:00
can1357 68992fbbf3 perf(pi-natives): optimized memory allocations by replacing Vec with SmallVec across modules
- Replaced heap-allocated Vec with stack-allocated SmallVec in grep module for context lines and type filters to reduce allocations.
- Optimized process tree data structure in ps module from Vec to SmallVec with capacity 4 for typical process child counts.
- Changed shell module to use SmallVec for process IDs collection, reducing heap allocations in abort operations.
- Refactored text module to use SmallVec for token and line collections, avoiding heap allocations for typical text wrapping scenarios.
- Increased work profiler stack capacity from 2 to 4 elements and optimized stack collection using iterator copy.
- Added work profile capture to debug report bundle for improved profiling insights.
2026-02-01 22:08:02 +01:00
can1357 951fc48eba feat(work): added work scheduling profiler with circular buffer sampling and flamegraph visualization
- Added work scheduling profiler with always-on circular buffer sampling to track CPU scheduling patterns and task execution times.
- Added `getWorkProfile()` native function to retrieve profiling data including folded stacks, markdown summary, SVG flamegraph, and metrics for the last N seconds.
- Added work profile debug menu item to visualize CPU scheduling patterns via flamegraph in the coding agent.
- Added work profile support to report bundles with folded stacks, summary, and flamegraph visualization.
- Updated `launch_blocking()` and `launch_async()` functions to accept task name tags for profiling instrumentation.
- Added dependencies on inferno, smallvec, and heapless crates for profiling infrastructure.
2026-02-01 22:04:15 +01:00
can1357 7233c4c8af fix: added windowsHide option to child process spawn calls
- Added `windowsHide: true` option to all child process spawn calls to prevent console windows from appearing on Windows systems.
2026-01-31 01:35:10 +01:00
can1357 8248b9e5ef feat(coding-agent/debug): added 'Open: artifact folder' menu option to debug selector for quick access to session artifacts
- Added 'Open: artifact folder' menu option to debug selector for quick access to session artifacts.
- Implemented handleOpenArtifacts() method to open session artifact directories in the native file manager with cross-platform support (macOS, Windows, Linux).
- Added fs/promises import for directory existence validation.
2026-01-30 01:04:54 +01:00
can1357 5503560d68 feat(coding-agent/debug): added interactive debug command with profiling and diagnostics
- Added interactive `/debug` command with menu-driven interface for bug report triage and system diagnostics.
- Implemented CPU profiling workflow allowing users to capture performance profiles during issue reproduction.
- Added heap snapshot generation for memory issue analysis and debugging.
- Implemented debug report bundle creation with session data, logs, system info, and optional profiling artifacts.
- Added system information collection and display including OS, CPU, memory, and version details.
- Implemented artifact cache management with size statistics and cleanup functionality.
2026-01-29 16:00:36 +01:00