Steve Yegge
298d559407
Remove unreachable utility functions (bd-224, bd-214)
...
- Remove duplicate computeIssueContentHash from sqlite/hash.go
- Remove FileUsed() from internal/config/config.go
- Remove verifyIssueOpen() test helper from git_sync_test.go
- Remove unimplemented SummarizeTier2 and all tier2 infrastructure from haiku.go
Removes ~120 LOC of dead code identified by deadcode analyzer.
Amp-Thread-ID: https://ampcode.com/threads/T-5f150c35-8d67-4dae-bb92-a7b5887d649d
Co-authored-by: Amp <amp@ampcode.com >
2025-10-27 20:45:59 -07:00
Steve Yegge
c2c7eda14f
Fix 15 lint errors: dupl, gosec, revive, staticcheck, unparam
...
Reduced golangci-lint issues from 56 to 41:
Fixed:
- dupl (2→0): Extracted parseLabelArgs helper, added nolint for cobra commands
- gosec G104 (4→0): Handle unhandled errors with _ = assignments
- gosec G302/G306 (4→0): Fixed file permissions from 0644 to 0600
- revive exported (4→0): Added proper godoc comments for all exported types
- staticcheck SA1019 (1→0): Removed deprecated netErr.Temporary() call
- staticcheck SA4003 (1→0): Removed impossible uint64 < 0 check
- unparam (8→0): Removed unused params/returns, added nolint where needed
Renamed types in compact package to avoid stuttering:
- CompactConfig → Config
- CompactResult → Result
Remaining 41 issues are documented baseline:
- gocyclo (24): High complexity in large functions
- gosec G204/G115 (17): False positives for subprocess/conversions
Closes bd-92
Amp-Thread-ID: https://ampcode.com/threads/T-1c136506-d703-4781-bcfa-eb605999545a
Co-authored-by: Amp <amp@ampcode.com >
2025-10-24 12:40:56 -07:00
Steve Yegge
9dcb86ebfb
Fix lint errors: handle errors, use fmt.Fprintf, apply De Morgan's law, use switch statements
...
Amp-Thread-ID: https://ampcode.com/threads/T-afcf56b0-a8bc-4310-bb59-1b63e1d70c89
Co-authored-by: Amp <amp@ampcode.com >
2025-10-24 12:27:07 -07:00
Steve Yegge
a86f3e139e
Add native Windows support ( #91 )
...
- Native Windows daemon using TCP loopback endpoints
- Direct-mode fallback for CLI/daemon compatibility
- Comment operations over RPC
- PowerShell installer script
- Go 1.24 requirement
- Cross-OS testing documented
Co-authored-by: danshapiro <danshapiro@users.noreply.github.com >
Amp-Thread-ID: https://ampcode.com/threads/T-c6230265-055f-4af1-9712-4481061886db
Co-authored-by: Amp <amp@ampcode.com >
2025-10-20 21:08:49 -07:00
Steve Yegge
0da81371b4
Implement Tier 1 compaction logic (bd-257)
...
- Add Compactor with CompactTier1 and CompactTier1Batch methods
- Single issue and batch compaction with 5 concurrent workers
- Dry-run mode for testing without API calls
- Smart size checking: keeps original if summary is longer
- Improved Haiku prompts to emphasize compression
- Add ApplyCompaction method for setting compaction metadata
- Comprehensive tests including API integration tests
- All tests passing
2025-10-15 23:31:43 -07:00
Steve Yegge
3e3f46d6d2
Add Claude Haiku client for issue compaction (bd-255)
...
- Implement HaikuClient with Tier 1 and Tier 2 summarization prompts
- Add exponential backoff retry logic for transient errors (network, 429, 5xx)
- API key precedence: env var overrides explicit key parameter
- Comprehensive tests with UTF-8 support and edge case coverage
- Retry logic only retries transient errors, stops on permanent failures
- Clarified retry semantics: maxRetries=3 means 4 total attempts (1 initial + 3 retries)
2025-10-15 23:09:33 -07:00