Commit Graph

18 Commits

Author SHA1 Message Date
yusyus
b636a0a292 fix: resolve issue #299 and Phase 1 cleanup
- Fix #299: rename --chunk-size/--chunk-overlap to --streaming-chunk-size/
  --streaming-overlap in arguments/package.py to avoid collision with the
  RAG --chunk-size flag from arguments/common.py
- Phase 1a: make package_skill.py import args via add_package_arguments()
  instead of a 105-line inline duplicate argparse block; fixes the root
  cause of _reconstruct_argv() passing unrecognised flag names
- Phase 1b: centralise setup_logging() into utils.py and remove 4
  duplicate module-level logging.basicConfig() calls from doc_scraper.py,
  github_scraper.py, codebase_scraper.py, and unified_scraper.py
- Fix test_package_structure.py / test_cli_paths.py version strings
  (3.1.1 → 3.1.2)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-24 21:22:05 +03:00
Claude
40cec4dffd hotfix: v3.1.1 — fix create command max_pages AttributeError
Merge fix from development (#293, #294) and bump version to 3.1.1.
Fixes crash when max_pages argument was not provided in web source routing.

https://claude.ai/code/session_01HS5q7ghjfEUravNPZRCGux
2026-02-23 06:37:39 +00:00
yusyus
f7117c35a9 chore: bump version to 3.1.0 and update CHANGELOG
- pyproject.toml: version 3.0.0 → 3.1.0
- src/skill_seekers/_version.py: update hardcoded fallback to 3.1.0
- CHANGELOG.md: comprehensive [3.1.0] release notes covering all
  features and fixes since v3.0.0 (unified create command, workflow
  presets, RST parser, smart enhance dispatcher, CLI flag parity,
  60 new workflow YAMLs, test suite improvements)
- Deprecation messages: update "removed in v3.0.0" → "v4.0.0" across
  analyze_presets.py, codebase_scraper.py, mcp/server.py
- tests/test_cli_paths.py: update version assertion to 3.1.0
- tests/test_package_structure.py: update __version__ assertions to 3.1.0
- tests/test_preset_system.py: update deprecation message version to v4.0.0

All 2267 tests passing.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-22 21:52:04 +03:00
yusyus
4deadd3800 test: Update version expectations from 2.9.0 to 3.0.0
- Update test_package_structure.py (4 assertions)
- Update test_cli_paths.py (1 assertion)
- Aligns tests with v3.0.0 major release
- Fixes 5 failing version check tests
2026-02-08 15:00:32 +03:00
yusyus
a67438bdcc fix: Update test version checks to 2.9.0 and remove whitespace
- Update version checks in test_package_structure.py from 2.8.0 to 2.9.0
- Update version check in test_cli_paths.py from 2.8.0 to 2.9.0
- Remove trailing whitespace from blank lines in code_analyzer.py (lines 1436-1504)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-03 21:00:34 +03:00
yusyus
ec9ee9dae8 test: Update version assertions to 2.8.0
Fix failing tests that were still checking for version 2.7.4
2026-02-01 17:30:27 +03:00
yusyus
91bd2184e5 fix: Resolve PDF processing (#267), How-To Guide (#242), Chinese README (#260) + code quality (#273)
Thanks @franklegolasyoung for the excellent work on the core fixes for issues #267, #242, and #260! 🙏

Your comprehensive approach to fixing PDF processing, expanding workflow detection, and improving the Chinese README documentation is much appreciated. I've added code quality fixes and comprehensive tests to ensure everything passes CI.

All 1266+ tests are now passing, and the issues are resolved! 🎉
2026-01-31 21:30:00 +03:00
yusyus
380a71c714 feat: Add discoverable 'analyze' subcommand with preset flags (Phase 1 UX improvement)
Implements Phase 1 of the codebase analysis UX improvement plan, making the
command discoverable and adding intuitive preset flags while maintaining 100%
backward compatibility.

New Features:
- Add 'analyze' subcommand to main CLI (skill-seekers analyze)
- Add --quick preset: Fast analysis (1-2 min, basic features only)
- Add --comprehensive preset: Full analysis (20-60 min, all features + AI)
- Add --enhance flag: Simple AI enhancement with auto-detection
- Improve help text with timing estimates and mode descriptions

Files Modified:
- src/skill_seekers/cli/main.py: Add analyze subcommand (lines 15, 273-311, 542-589)
- src/skill_seekers/cli/codebase_scraper.py: Add preset logic and improve help text
- tests/test_analyze_command.py: NEW - 20 comprehensive tests
- tests/test_cli_paths.py: Fix version check (2.7.0 -> 2.7.2)
- tests/test_package_structure.py: Fix 4 version checks (2.7.0 -> 2.7.2)
- README.md: Update examples to use 'analyze' command
- CLAUDE.md: Update examples to use 'analyze' command

Test Results:
- 81 tests related to Phase 1: ALL PASSING 
- 20 new tests for analyze command: ALL PASSING 
- Zero regressions introduced
- 100% backward compatibility maintained

Backward Compatibility:
- Old 'skill-seekers-codebase' command still works
- All existing flags (--depth, --ai-mode, --skip-*) still functional
- No breaking changes

Usage Examples:
  skill-seekers analyze --directory . --quick
  skill-seekers analyze --directory . --comprehensive
  skill-seekers analyze --directory . --enhance

Fixes #262 (codebase UX issues)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-29 21:52:46 +03:00
yusyus
86c68a3465 test: Update version expectations to 2.7.0 and fix MCP server reference
- Update test_package_structure.py: Change version checks from 2.5.2 to 2.7.0
- Fix docs/QUICK_REFERENCE.md: Update server reference from server.py to server_fastmcp.py

Fixes 5 failing tests:
- test_cli_has_version
- test_mcp_has_version
- test_mcp_tools_has_version
- test_root_has_version
- test_documentation_references_correct_paths

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-18 01:50:59 +03:00
Pablo Estevez
c33c6f9073 change max lenght 2026-01-17 17:48:15 +00:00
Pablo Estevez
5ed767ff9a run ruff 2026-01-17 17:29:21 +00:00
yusyus
2ebf6c8cee chore: Bump version to v2.5.2 - Package Configuration Improvement
- Switch from manual package listing to automatic discovery
- Improves maintainability and prevents missing module bugs
- All tests passing (700+ tests)
- Package contents verified identical to v2.5.1

Fixes #226
Merges #227

Thanks to @iamKhan79690 for the contribution!

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Co-Authored-By: Anas Ur Rehman (@iamKhan79690) <noreply@github.com>
2026-01-01 18:57:21 +03:00
yusyus
3e36571b47 test: Update all version assertions to 2.5.1
Fixed version assertions in test_package_structure.py:
- test_cli_has_version: 2.0.0 → 2.5.1
- test_mcp_has_version: 2.4.0 → 2.5.1
- test_mcp_tools_has_version: 2.4.0 → 2.5.1
- test_root_has_version: 2.0.0 → 2.5.1

Related: v2.5.1 version bump
2025-12-30 23:30:36 +03:00
yusyus
9e41094436 feat: v2.4.0 - MCP 2025 upgrade with multi-agent support (#217)
* feat: v2.4.0 - MCP 2025 upgrade with multi-agent support

Major MCP infrastructure upgrade to 2025 specification with HTTP + stdio
transport and automatic configuration for 5+ AI coding agents.

### 🚀 What's New

**MCP 2025 Specification (SDK v1.25.0)**
- FastMCP framework integration (68% code reduction)
- HTTP + stdio dual transport support
- Multi-agent auto-configuration
- 17 MCP tools (up from 9)
- Improved performance and reliability

**Multi-Agent Support**
- Auto-detects 5 AI coding agents (Claude Code, Cursor, Windsurf, VS Code, IntelliJ)
- Generates correct config for each agent (stdio vs HTTP)
- One-command setup via ./setup_mcp.sh
- HTTP server for concurrent multi-client support

**Architecture Improvements**
- Modular tool organization (tools/ package)
- Graceful degradation for testing
- Backward compatibility maintained
- Comprehensive test coverage (606 tests passing)

### 📦 Changed Files

**Core MCP Server:**
- src/skill_seekers/mcp/server_fastmcp.py (NEW - 300 lines, FastMCP-based)
- src/skill_seekers/mcp/server.py (UPDATED - compatibility shim)
- src/skill_seekers/mcp/agent_detector.py (NEW - multi-agent detection)

**Tool Modules:**
- src/skill_seekers/mcp/tools/config_tools.py (NEW)
- src/skill_seekers/mcp/tools/scraping_tools.py (NEW)
- src/skill_seekers/mcp/tools/packaging_tools.py (NEW)
- src/skill_seekers/mcp/tools/splitting_tools.py (NEW)
- src/skill_seekers/mcp/tools/source_tools.py (NEW)

**Version Updates:**
- pyproject.toml: 2.3.0 → 2.4.0
- src/skill_seekers/cli/main.py: version string updated
- src/skill_seekers/mcp/__init__.py: 2.0.0 → 2.4.0

**Documentation:**
- README.md: Added multi-agent support section
- docs/MCP_SETUP.md: Complete rewrite for MCP 2025
- docs/HTTP_TRANSPORT.md (NEW)
- docs/MULTI_AGENT_SETUP.md (NEW)
- CHANGELOG.md: v2.4.0 entry with migration guide

**Tests:**
- tests/test_mcp_fastmcp.py (NEW - 57 tests)
- tests/test_server_fastmcp_http.py (NEW - HTTP transport tests)
- All existing tests updated and passing (606/606)

###  Test Results

**E2E Testing:**
- Fresh venv installation: 
- stdio transport: 
- HTTP transport:  (health check, SSE endpoint)
- Agent detection:  (found Claude Code)
- Full test suite:  606 passed, 152 skipped

**Test Coverage:**
- Core functionality: 100% passing
- Backward compatibility: Verified
- No breaking changes: Confirmed

### 🔄 Migration Path

**Existing Users:**
- Old `python -m skill_seekers.mcp.server` still works
- Existing configs unchanged
- All tools function identically
- Deprecation warnings added (removal in v3.0.0)

**New Users:**
- Use `./setup_mcp.sh` for auto-configuration
- Or manually use `python -m skill_seekers.mcp.server_fastmcp`
- HTTP mode: `--http --port 8000`

### 📊 Metrics

- Lines of code: 2200 → 300 (87% reduction in server.py)
- Tools: 9 → 17 (88% increase)
- Agents supported: 1 → 5 (400% increase)
- Tests: 427 → 606 (42% increase)
- All tests passing: 

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

* fix: Add backward compatibility exports to server.py for tests

Re-export tool functions from server.py to maintain backward compatibility
with test_mcp_server.py which imports from the legacy server module.

This fixes CI test failures where tests expected functions like list_tools()
and generate_config_tool() to be importable from skill_seekers.mcp.server.

All tool functions are now re-exported for compatibility while maintaining
the deprecation warning for direct server execution.

* fix: Export run_subprocess_with_streaming and fix tool schemas for backward compatibility

- Add run_subprocess_with_streaming export from scraping_tools
- Fix tool schemas to include properties field (required by tests)
- Resolves 9 failing tests in test_mcp_server.py

* fix: Add call_tool router and fix test patches for modular architecture

- Add call_tool function to server.py for backward compatibility
- Fix test patches to use correct module paths (scraping_tools instead of server)
- Update 7 test decorators to patch the correct function locations
- Resolves remaining CI test failures

---------

Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-26 00:45:48 +03:00
yusyus
ce1c07b437 feat: Add modern Python packaging - Phase 1 (Foundation)
Implements issue #168 - Modern Python packaging with uv support

This is Phase 1 of the modernization effort, establishing the core
package structure and build system.

## Major Changes

### 1. Migrated to src/ Layout
- Moved cli/ → src/skill_seekers/cli/
- Moved skill_seeker_mcp/ → src/skill_seekers/mcp/
- Created root package: src/skill_seekers/__init__.py
- Updated all imports: cli. → skill_seekers.cli.
- Updated all imports: skill_seeker_mcp. → skill_seekers.mcp.

### 2. Created pyproject.toml
- Modern Python packaging configuration
- All dependencies properly declared
- 8 CLI entry points configured:
  * skill-seekers (unified CLI)
  * skill-seekers-scrape
  * skill-seekers-github
  * skill-seekers-pdf
  * skill-seekers-unified
  * skill-seekers-enhance
  * skill-seekers-package
  * skill-seekers-upload
  * skill-seekers-estimate
- uv tool support enabled
- Build system: setuptools with wheel

### 3. Created Unified CLI (main.py)
- Git-style subcommands (skill-seekers scrape, etc.)
- Delegates to existing tool main() functions
- Full help system at top-level and subcommand level
- Backwards compatible with individual commands

### 4. Updated Package Versions
- cli/__init__.py: 1.3.0 → 2.0.0
- mcp/__init__.py: 1.2.0 → 2.0.0
- Root package: 2.0.0

### 5. Updated Test Suite
- Fixed test_package_structure.py for new layout
- All 28 package structure tests passing
- Updated all test imports for new structure

## Installation Methods (Working)

```bash
# Development install
pip install -e .

# Run unified CLI
skill-seekers --version  # → 2.0.0
skill-seekers --help

# Run individual tools
skill-seekers-scrape --help
skill-seekers-github --help
```

## Test Results
- Package structure tests: 28/28 passing 
- Package installs successfully 
- All entry points working 

## Still TODO (Phase 2)
- [ ] Run full test suite (299 tests)
- [ ] Update documentation (README, CLAUDE.md, etc.)
- [ ] Test with uv tool run/install
- [ ] Build and publish to PyPI
- [ ] Create PR and merge

## Breaking Changes
None - fully backwards compatible. Old import paths still work.

## Migration for Users
No action needed. Package works with both pip and uv.

Closes #168 (when complete)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-07 01:14:24 +03:00
yusyus
0929649408 test: Update version assertion to 1.3.0 in test_package_structure
Update expected version from 1.2.0 to 1.3.0 in test_cli_has_version

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-26 13:23:07 +03:00
yusyus
7cc3d8b175 Fix all tests: 297/297 passing, 0 skipped, 0 failed
CHANGES:

1. **Fixed 9 PDF Scraper Test Failures:**
   - Added .get() safety for missing page keys (headings, text, code_blocks, images)
   - Supported both 'code_samples' and 'code_blocks' keys for compatibility
   - Fixed extract_pdf() to raise RuntimeError on failure (tests expect exception)
   - Added image saving functionality to _generate_reference_file()
   - Updated all test methods to override skill_dir with temp directory
   - Fixed categorization to handle pre-categorized test data

2. **Fixed 25 MCP Test Skips:**
   - Renamed mcp/ directory to skill_seeker_mcp/ to avoid shadowing external mcp package
   - Updated all imports in tests/test_mcp_server.py
   - Simplified skill_seeker_mcp/server.py import logic (no more shadowing workarounds)
   - Updated tests/test_package_structure.py to reference skill_seeker_mcp

3. **Test Results:**
   -  297 tests passing (100%)
   -  0 tests skipped
   -  0 tests failed
   - All test categories passing:
     * 23 package structure tests
     * 18 PDF scraper tests
     * 67 PDF extractor/advanced tests
     * 25 MCP server tests
     * 164 other core tests

BREAKING CHANGE: MCP server directory renamed from `mcp/` to `skill_seeker_mcp/`

📦 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-26 00:51:18 +03:00
yusyus
cb0d3e885e fix: Resolve MCP package shadowing issue and add package structure tests
🐛 Fixes:
- Fix mcp package shadowing by importing external MCP before sys.path modification
- Update mcp/server.py to avoid shadowing installed mcp package
- Update tests/test_mcp_server.py import order

 Tests Added:
- Add tests/test_package_structure.py with 23 comprehensive tests
- Test cli package structure and imports
- Test mcp package structure and imports
- Test backwards compatibility
- All package structure tests passing 

📊 Test Results:
- 205 tests passed 
- 67 tests skipped (PDF features, PyMuPDF not installed)
- 23 new package structure tests added
- Total: 272 tests (excluding test_mcp_server.py which needs more work)

⚠️ Known Issue:
- test_mcp_server.py still has import issues (67 tests)
- Will be fixed in next commit
- Main functionality tests all passing

Impact: Package structure working, 75% of tests passing
2025-10-26 00:26:57 +03:00