Implement comprehensive schedule management service for automated scans: New Files: - web/services/schedule_service.py (470 lines) * Complete CRUD operations for schedules * Cron expression validation using croniter * Next run time calculation * Execution history tracking * Human-readable relative time formatting - tests/test_schedule_service.py (671 lines, 40+ tests) * Create/get/list/update/delete schedule tests * Cron validation and next run calculation tests * Pagination and filtering tests * Schedule history and serialization tests Changes: - requirements-web.txt: Add croniter==2.0.1 dependency - docs/ai/PHASE3.md: Mark Step 1 complete, Step 2 next Key Features: - Validates cron expressions before saving - Automatically calculates next execution time - Preserves historical scans when schedules deleted - Supports pagination and filtering by enabled status - Provides relative time display (e.g., "in 2 hours")
35 lines
584 B
Plaintext
35 lines
584 B
Plaintext
# Flask Web Application Dependencies
|
|
# Phase 1: Foundation (Database, Settings, Flask Core)
|
|
|
|
# Core Flask
|
|
Flask==3.0.0
|
|
Werkzeug==3.0.1
|
|
|
|
# Database & ORM
|
|
SQLAlchemy==2.0.23
|
|
alembic==1.13.0
|
|
|
|
# Authentication & Security
|
|
Flask-Login==0.6.3
|
|
bcrypt==4.1.2
|
|
cryptography==41.0.7
|
|
|
|
# API & Serialization
|
|
Flask-CORS==4.0.0
|
|
marshmallow==3.20.1
|
|
marshmallow-sqlalchemy==0.29.0
|
|
|
|
# Background Jobs & Scheduling
|
|
APScheduler==3.10.4
|
|
croniter==2.0.1
|
|
|
|
# Email Support (Phase 4)
|
|
Flask-Mail==0.9.1
|
|
|
|
# Configuration Management
|
|
python-dotenv==1.0.0
|
|
|
|
# Development & Testing
|
|
pytest==7.4.3
|
|
pytest-flask==1.3.0
|