Skip to content

Comments

Validation and audit#8

Merged
bigr merged 5 commits intomainfrom
klinger-validation-and-audit
Oct 23, 2025
Merged

Validation and audit#8
bigr merged 5 commits intomainfrom
klinger-validation-and-audit

Conversation

@bigr
Copy link
Owner

@bigr bigr commented Oct 23, 2025

No description provided.

bigr added 5 commits October 23, 2025 10:02
- Add sync_app function to regenerate wrapper and desktop files
- Validate manifest exists and has required fields
- Check for manual file modifications and warn user
- Update manifest modified timestamp after sync
- Support dry-run mode for preview without changes
- Integrate sync command into CLI with proper error handling
- Add comprehensive unit tests (8 test cases)
- All tests passing, linting clean, type checking successful

Execution report:
- Unit tests: 8/8 passed (test_sync.py)
- Integration: CLI command wired and tested
- Ruff: 0 issues
- Mypy: Success (strict mode)
- Pre-commit hooks: All passed
- Add comprehensive audit_app function with 11 validation checks
- Check manifest existence, YAML validity, and required fields
- Verify desktop file format and required keys
- Validate wrapper script existence and executable permissions
- Check browser executable availability
- Verify profile directory and icon existence
- Check handler registration for userscript-enabled PWAs
- Support fix mode to auto-repair using sync command
- Add rich CLI output with colored status symbols
- Integrate audit command with detailed help and examples
- Add comprehensive unit tests (10 test cases)
- All tests passing, linting clean, type checking successful

Execution report:
- Unit tests: 10/10 passed (test_audit.py)
- Integration: CLI command wired with rich output
- Total tests: 223/223 passed
- Ruff: 0 issues
- Mypy: Success (strict mode)
- Pre-commit hooks: All passed
- Add edit_app function to open manifest in $EDITOR
- Detect editor from $EDITOR env var with fallbacks to vi/nano/vim
- Create automatic backup before editing
- Validate YAML syntax and required fields after edit
- Restore backup if validation fails
- Support auto-sync mode to regenerate artifacts after edit
- Add --no-sync flag to skip automatic regeneration
- Integrate edit command with rich CLI output
- Add comprehensive unit tests (8 test cases)
- All tests passing, linting clean, type checking successful

Execution report:
- Unit tests: 8/8 passed (test_edit.py)
- Integration: CLI command wired with validation and sync
- Total tests: 231/231 passed
- Ruff: 0 issues
- Mypy: Success (strict mode)
- Pre-commit hooks: All passed
- Test audit detection and fix of missing files
- Test edit and sync workflow with manifest changes
- Test manual sync after edit with --no-sync flag
- Test audit detection of manual file modifications
- Test complete workflow: add -> audit -> edit -> sync
- All 5 integration tests passing
- Total test count: 236 tests passing

Execution report:
- Integration tests: 5/5 passed
- Total tests: 236/236 passed (unit + integration)
- Ruff: 0 issues
- Mypy: Success
- Pre-commit hooks: All passed
- Mark all Phase 5 checklist items as completed
- Update status summary to reflect Phase 5 completion
- Update test count to 236 tests
- Update estimated remaining work (Phases 6-7)
- Document 11 fully implemented commands

Phase 5 achievements:
- audit command: 11 validation checks with fix mode
- sync command: regenerate artifacts from manifest
- edit command: $EDITOR integration with validation
- 26 unit tests added (8 sync, 10 audit, 8 edit)
- 5 integration tests for workflow validation
- Total: 236 tests passing
@bigr bigr merged commit 6b3e9a5 into main Oct 23, 2025
5 checks passed
bigr added a commit that referenced this pull request Oct 23, 2025
- Add validation to prevent simultaneous use of conflicting flags
- Raise UsageError with clear message when both are specified
- Add test coverage for mutual exclusion behavior
- Resolves user testing issue #8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant