- Introduced the HistoricalImportJob model to track historical data import jobs.
- Implemented asynchronous job processing for importing historical activity data from media servers.
- Enhanced the activity settings page to allow users to specify the number of days back for historical imports.
- Added a new route to display recent historical import jobs.
- Updated the import_historical_activity function to create and manage import jobs.
- Improved UI components for displaying success and error messages related to historical imports.
- Added migration script to create the historical_import_job table in the database.
Migration Changes:
- Renamed migration file from 20251004 to 20251005
- Updated down_revision from fd5a34530162 to 08a6c8fb44db
- Ensures migration runs after upstream notification events migration
- Fixes migration chain branching issue
- Removed incorrect merge migration (1e83c67d9785)
Migration chain is now:
fd5a34530162 (disabled attribute) → 08a6c8fb44db (notification events)
→ 20251005_add_category_to_wizard_step (wizard category)
Wizard Refactoring:
- Enhanced uniqueness constraint for WizardStep from (server_type, position)
to (server_type, category, position)
- Ensures steps in different categories (pre_invite vs post_invite) can have
the same position indexing without conflict
- Updated wizard state management documentation to explicitly list and
describe data-* attributes used in steps.html template
Code Quality:
- Applied djlint formatting to 8 template files to minimize rebase conflicts
- Applied ruff format and ruff check --fix (no changes needed)
- Removed redundant requirement comments from spec-driven development
- Fixed case sensitivity in test assertion (POST vs post)
- Updated test references from 20251004 to 20251005 to match corrected
migration revision ID
- Added columns `wizarr_user_id` and `wizarr_identity_id` to the `activity_session` table.
- Created foreign key constraints for the new columns linking to `user` and `identity` tables.
- Created indexes for the new columns to improve query performance.
- Dropped the `ended_at` column from the `activity_session` table.
- Added a new `active` column to the `activity_session` table with a default value of true.
- Created an index for the `active` column to enhance query efficiency.
- Introduced `is_disabled` attribute to the User model.
- Added `expiry_action` selection in the GeneralSettingsForm for user management.
- Implemented `disable_user` methods for various media clients (Audiobookshelf, Jellyfin, Kavita, etc.) to handle user disabling.
- Updated `check_expiring` task to process expired users based on the new settings.
- Enhanced user interface to reflect disabled status in user cards.
- Added migration for the new `is_disabled` column in the user table.
- Fix test database isolation by cleaning WizardStep data before tests run
- Remove unused imports and fix import ordering
- Replace setattr with direct attribute assignment
- Use contextlib.suppress for cleaner exception handling
- Fix nested if statement in wizard_export_import.py
Fixes the failing CI checks for PR #817.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Add comprehensive "require interaction" functionality for wizard steps that prevents users from proceeding until they engage with step content.
## Key Features:
- **Database Integration**: New `require_interaction` boolean field in WizardStep model with migration
- **Frontend Gating**: Robust JavaScript system that disables "Next" button until user clicks links/buttons in step content
- **UI Enhancement**: Improved checkbox forms with clear descriptions and visual indicators
- **Event Handling**: Advanced interaction detection with proper HTMX disabling and event capture
- **Admin Interface**: Full integration with wizard configuration forms (main and simple)
- **Export/Import**: Support for require_interaction field in wizard step data operations
## Technical Implementation:
- Disabled button state management with pointer-events and tabindex control
- HTMX attribute manipulation to prevent premature navigation
- Event listener capture phase handling for reliable interaction blocking
- Comprehensive test coverage for interaction scenarios
- Form validation and user experience improvements
## Files Modified:
- Backend: models, routes, forms, services, migration
- Frontend: JavaScript interaction logic, templates, UI components
- Testing: Complete test suite for interaction requirements
This feature ensures users engage with critical wizard content before proceeding, improving onboarding experience and preventing accidental step skipping.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Remove all migration helper scripts (over-engineering)
- Revert Docker entrypoint changes (not needed)
- Clean up CLAUDE.md migration strategy section
- Keep only the essential: beautifully renamed migration files
The simple solution won: just rename the files, Alembic doesn't care about filenames!
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
BREAKING CHANGE: Migration files renamed to clean YYYYMMDD format
- Renamed 17 migrations from chaotic hash-based to clean date-based names
- Maintained all revision IDs and dependency chains
- Updated Docker entrypoint to check/log migration mappings
- All tests pass, migration chain validated and healthy
- 28/30 migrations now follow YYYYMMDD_description.py format
- Added comprehensive migration management tooling
Changes:
- migrations/versions/*: 17 files renamed to YYYYMMDD format using real creation dates
- docker-entrypoint.sh: Added migration name checker before DB migrations
- Complete 4-phase renaming strategy implemented and executed
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Updated `InvitationCreateRequest` model to change `server_ids` from required to optional with improved description.
- Enhanced `library_model` to include `external_id`, `server_name`, and `enabled` fields.
- Modified `InvitationFlowManager` to prioritize new many-to-many relationship checks for invitations.
- Created a new migration file to merge branches related to API key and foreign key improvements.
- Added comprehensive tests for API endpoints, including status, users, invitations, libraries, servers, and API key management.
- Implemented error handling tests for malformed JSON and inactive API keys.
- Updated the tag fetching logic in the GitHub Actions workflow to prioritize 2025.x.x format over v4.x.x for latest version retrieval.
- Modified the invitation deletion logic to use SQLAlchemy's delete method for better integrity and cascading behavior.
- Added CASCADE constraints to foreign key relationships in the database models to ensure proper deletion behavior.
- Improved the invitation flow manager to handle potential non-iterable server relationships gracefully.
- Updated notification service to ensure boolean return values for notification results.
- Adjusted migration scripts to use timezone-aware datetime for created_at fields.
- Added comprehensive tests for migration upgrades from the latest release to ensure stability and integrity.
- Enhanced WebAuthn security checks to allow localhost in testing environments.
- Refactored pre-commit configuration to remove unused hooks and streamline testing processes.
- Added new agents for backend logic, HTMX frontend, integration orchestration, QA test automation, and Tailwind UI styling to improve development workflows.
Adds existence checks to migration to handle edge case where:
1. Watchtower starts container update during migration
2. Migration creates tables but gets interrupted before completion
3. New container tries to run same migration again → table exists error
Fixes#747🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add new connections management system with MediaConnection and DiscordWebhook models
- Implement dynamic server configuration with URL field support
- Add expiry management system with automatic user cleanup
- Create wizard preset system for streamlined server setup
- Add dedicated connections interface in settings with CRUD operations
- Integrate expiry functionality with connection management
- Add proper form validation and error handling
- Update templates and routes for new connection workflow
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Fixed SIM117 ruff linting errors by combining nested with statements
- All WebAuthn security tests still pass after refactoring
- Code is now more readable and follows modern Python patterns
- Applied ruff formatting to WebAuthn routes file
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>