Tree:
b6d9b29720
ai-context
app_id_fix
build-ios
cross-platform-factory
cross-platform-factory-redux
d9085ced6df7dc7bdcd899959cea6489cab7f8b8
db-backup-cross-platform
deep-fix
deep_linking
design-tweaks-2023-12
elec-tweak
electron_fix_20250317
experimental_plugin
eye-slash
feat/image-feed-view-improvements
fix-service-worker
friend-tech-inspired-pwa-dialog
gifting-ui-2025-05
home-icon-enhancements
home-view-notification-improvements
homeview-cleanup-2025-03
homeview-refresh-2025-02
invite-client-side
main
master
new-storage
nostr
notification-request-permission-dialog
notify-time
offer-edit
passkey
passkey-cache
photo-reverse
plan-loc
playwright-pwa-install-test
profile-pic
project-gives
qrcode-capacitor
qrcode-reboot
registration-gate
remove-old-alerts
search-map-fix
side_step
simple-signer
split_build_process
sql-absurd-sql
sql-absurd-sql-back
sql-absurd-sql-further
sql-absurd-sql-further2
sql-wa-sqlite
starred-projects
sw-cleanup
tmp
trent-tweaks
tweaks
ui-fixes-2024-03
ui-fixes-2025-03
v-onboarding-2024-04
vite-version
why-migrate-fail
0.1.8
0.2.1
0.2.11
0.2.17
0.2.2
0.2.4
0.3.35
0.3.50
0.3.51
0.3.52
0.3.53
0.3.54
0.3.55
0.3.56
0.3.57
0.4.1
0.4.2
0.4.3
0.4.4
${ noResults }
12 Commits (b6d9b29720080a8b8cf7c9f11fda8d7cf10202f1)
Author | SHA1 | Message | Date |
---|---|---|---|
|
b6d9b29720 |
refactor(sqlite): align database implementation with sacred-sql
BREAKING CHANGE: Removes database encryption in favor of simpler implementation - Remove encryption from SQLite initialization and connection options - Change journal mode from WAL to MEMORY to match sacred-sql - Simplify PRAGMA settings and remove WAL-specific configurations - Remove secret table and encryption-related migrations - Update database schema to use non-encrypted storage - Clean up database initialization process This change aligns the TimeSafari Electron SQLite implementation with sacred-sql, improving compatibility and simplifying the database layer. Existing databases will need to be cleared and recreated due to the removal of encryption support. Migration: 1. Delete existing database at ~/Databases/TimeSafari/timesafariSQLite.db 2. Restart application to create fresh database with new schema |
3 days ago |
|
409de21fc4 |
fix(db): resolve SQLite channel and initialization issues
- Add sqlite-status to valid IPC channels - Fix SQLite ready signal handling - Improve database status tracking - Add proper error handling for status updates - Keep database connection open during initialization Technical Details: - Added sqlite-status to VALID_CHANNELS.invoke list - Implemented sqlite-status handler with proper verification - Added database open state verification - Improved error handling and logging - Fixed premature database closing Testing Notes: - Verify SQLite ready signal is received correctly - Confirm database stays open after initialization - Check status updates are processed properly - Verify error handling for invalid states Security: - Validates all IPC channels - Verifies database state before operations - Maintains proper connection lifecycle - Implements proper error boundaries Author: Matthew Raymer |
4 days ago |
|
b6ee30892f |
feat(sqlite): enhance SQLite initialization and IPC handlers
This commit significantly improves SQLite database management and IPC communication in the TimeSafari Electron app. Key changes include: - Add new IPC handlers for database lifecycle management: - sqlite-open: Open database connections - sqlite-close: Close database connections - sqlite-is-db-open: Check database connection status - get-path: Retrieve database path - get-base-path: Get base directory path - Enhance SQLite initialization with: - Improved error handling and recovery mechanisms - Detailed logging for all database operations - State verification and tracking - Proper cleanup of IPC handlers - Transaction state management - Security improvements: - Validate all IPC channels - Implement proper file permissions (0o755) - Add connection state verification - Secure error handling and logging - Performance optimizations: - Implement WAL journal mode - Configure optimal PRAGMA settings - Add connection pooling support - Implement retry logic with exponential backoff Technical details: - Add SQLiteError class for detailed error tracking - Implement handler registration tracking - Add comprehensive logging with operation tagging - Update preload script with new valid channels - Add type definitions for all SQLite operations Testing: - All handlers include proper error handling - State verification before operations - Recovery mechanisms for failed operations - Logging for debugging and monitoring Author: Matthew Raymer |
4 days ago |
|
340e718199 |
feat(logging): enhance SQLite logging and IPC handler management
- Add Winston-based structured logging system with: - Separate console and file output formats - Custom SQLite and migration loggers - Configurable log levels and verbosity - Log rotation and file management - Type-safe logger extensions - Improve IPC handler management: - Add handler registration tracking - Implement proper cleanup before re-registration - Fix handler registration conflicts - Add better error handling for IPC operations - Add migration logging controls: - Configurable via DEBUG_MIGRATIONS env var - Reduced console noise while maintaining file logs - Structured migration status reporting Security: - Add proper log file permissions (0o755) - Implement log rotation to prevent disk space issues - Add type safety for all logging operations - Prevent handler registration conflicts Dependencies: - Add winston for enhanced logging - Remove deprecated @types/winston This change improves debugging capabilities while reducing console noise and fixing IPC handler registration issues that could cause database operation failures. |
5 days ago |
|
ec74fff892 |
refactor: enhance SQLite error handling and type safety
Current State: - SQLite initialization completes successfully - API exposure and IPC bridge working correctly - Type definitions and interfaces properly implemented - Enhanced error handling with specific error codes - Comprehensive logging system in place Critical Issue Identified: SQLite initialization timeout causing cascading failures: - Components attempting database operations before initialization complete - Error logging failing due to database unavailability - Multiple components affected (HomeView, AccountView, ImageMethodDialog) - User experience impacted with cache clear prompts Changes Made: - Added proper TypeScript interfaces for SQLite operations - Enhanced SQLiteError class with error codes and context - Implemented input validation utilities - Added detailed logging with timestamps - Improved error categorization and handling - Added result structure validation Type Definitions Added: - SQLiteConnectionOptions - SQLiteQueryOptions - SQLiteExecuteOptions - SQLiteResult - SQLiteEchoResult Error Codes Implemented: - SQLITE_BUSY - SQLITE_NO_TABLE - SQLITE_SYNTAX_ERROR - SQLITE_PLUGIN_UNAVAILABLE - SQLITE_INVALID_OPTIONS - SQLITE_MIGRATION_FAILED - SQLITE_INVALID_RESULT - SQLITE_ECHO_MISMATCH Next Steps: 1. Implement initialization synchronization 2. Add component loading states 3. Improve error recovery mechanisms 4. Add proper error boundaries 5. Implement fallback UI states Affected Files: - electron/src/rt/sqlite-init.ts - src/types/electron.d.ts Note: This is a transitional commit. While the structure and type safety are improved, the initialization timeout issue needs to be addressed in the next commit to prevent cascading failures. Testing Required: - SQLite initialization timing - Component loading sequences - Error recovery scenarios - Database operation retries |
5 days ago |
|
91a1c05473 |
fix(electron): consolidate SQLite initialization and IPC handling
- Consolidate preload script with secure IPC bridge and channel validation - Ensure single initialization path in main process - Add robust error handling and user feedback - Fix race conditions in window creation and SQLite ready signal Current state: - SQLite initializes successfully in main process - IPC bridge is established and events are transmitted - Window creation and loading sequence is correct - Renderer receives ready signal and mounts app - Database operations still fail in renderer due to connection issues Known issues: - SQLite proxy not properly initialized in renderer - Database connection not established in renderer - Error logging attempts to use database before ready - Connection state management needs improvement This commit represents a stable point where IPC communication is working but database operations need to be fixed. |
5 days ago |
|
28c114a2c7 |
fix(sqlite): resolve migration issues and enhance documentation
This commit addresses critical SQLite migration issues and significantly improves code documentation and error handling. The changes include both functional fixes and comprehensive documentation updates. Key Changes: - Fix migration name binding issue by switching to direct SQL statements - Add proper SQL value escaping to prevent injection - Implement comprehensive error handling and recovery - Add detailed logging throughout migration process - Enhance transaction safety and state verification Documentation Updates: - Add comprehensive module-level documentation - Document all major functions with JSDoc - Add security and performance considerations - Include detailed process flows - Document error handling strategies Technical Details: - Switch from parameterized queries to direct SQL for schema_version updates - Add proper string escaping for SQL values - Implement state verification before/after operations - Add detailed debug logging for migration process - Enhance error recovery with proper state tracking Security: - Add SQL injection prevention - Implement proper value escaping - Add transaction isolation - Enhance state verification - Add error sanitization Performance: - Optimize transaction handling - Implement efficient SQL parsing - Add connection pooling - Reduce locking contention - Optimize statement reuse Testing: - Verified migration process with fresh database - Tested error recovery scenarios - Validated transaction safety - Confirmed proper state tracking - Verified logging completeness Breaking Changes: None Migration Required: Yes (database will be recreated) Author: Matthew Raymer |
7 days ago |
|
786f07e067 |
feat(electron): Implement SQLite database initialization with proper logging
- Add comprehensive logging for database operations - Implement proper database path handling and permissions - Set up WAL journal mode and PRAGMA configurations - Create initial database schema with tables and triggers - Add retry logic for database operations - Implement proper error handling and state management Current state: - Database initialization works in main process - Connection creation succeeds with proper permissions - Schema creation and table setup complete - Logging system fully implemented - Known issue: Property name mismatch between main process and renderer causing read-only mode conflicts (to be fixed in next commit) Technical details: - Uses WAL journal mode for better concurrency - Implements proper file permissions checking - Sets up foreign key constraints - Creates tables: users, time_entries, time_goals, time_goal_entries - Adds automatic timestamp triggers - Implements proper connection lifecycle management Security: - Proper file permissions (755 for directory) - No hardcoded credentials - Proper error handling and logging - Safe file path handling Author: Matthew Raymer |
1 week ago |
|
710cc1683c |
fix(sqlite): Standardize connection options and improve error handling
Changes to sqlite-init.ts: - Standardized connection options format between main and renderer processes - Added explicit mode: 'rwc' to force read-write-create mode - Added connection registration verification - Added detailed logging of actual file paths - Added journal mode verification to detect read-only state - Removed redundant PRAGMA settings (now handled in main process) - Added more detailed error reporting for connection failures Security: - Ensures consistent read-write permissions across processes - Verifies database is not opened in read-only mode - Maintains proper file permissions (644) and directory permissions (755) Testing: - Verified connection creation in both main and renderer processes - Confirmed journal mode is set correctly - Validated connection registration - Tested error handling for invalid states Author: Matthew Raymer |
1 week ago |
|
ebef5d6c8d |
feat(sqlite): Initialize database with complete schema and PRAGMAs
Initial database setup with: - Created database at /home/matthew/Databases/TimeSafari/timesafariSQLite.db - Set optimized PRAGMAs for performance and safety: * WAL journal mode for better concurrency * Foreign key constraints enabled * Normal synchronous mode * Memory temp store * 4KB page size * 2000 page cache (8MB) - Created core tables: * schema_version (for migration tracking) * users (for user management) * time_entries (for time tracking) * time_goals (for goal setting) * time_goal_entries (for goal tracking) - Added automatic timestamp triggers for: * users.updated_at * time_entries.updated_at * time_goals.updated_at - Fixed connection handling to work with plugin's undefined return pattern - Added rich logging throughout initialization process Security: - Database created with proper permissions (644) - Directory permissions set to 755 - No encryption (as per requirements) - Foreign key constraints enabled for data integrity Testing: - Verified table creation - Confirmed schema version tracking - Validated connection registration - Tested WAL mode activation Author: Matthew Raymer |
1 week ago |
|
57191df416 |
feat(sqlite): Database file creation working, connection pending
- Successfully creates database file using plugin's open() method - Directory permissions and path handling verified working - Plugin initialization and echo test passing - Database file created at /home/matthew/Databases/TimeSafari/timesafariSQLite.db Key findings: - createConnection() returns undefined but doesn't error - open() silently creates the database file - Connection retrieval still needs work (getDatabaseConnectionOrThrowError fails) - Plugin structure confirmed: both class and default export available Next steps: - Refine connection handling after database creation - Add connection state verification - Consider adding retry logic for connection retrieval Technical details: - Using CapacitorSQLite from @capacitor-community/sqlite/electron - Database path: /home/matthew/Databases/TimeSafari/timesafariSQLite.db - Directory permissions: 755 (rwxr-xr-x) - Plugin version: 6.x (Capacitor 6+ compatible) |
1 week ago |
|
900c2521c7 |
WIP: Improve SQLite initialization and error handling
- Implement XDG Base Directory Specification for data storage - Use $XDG_DATA_HOME (defaults to ~/.local/share) for data files - Add proper directory permissions (700) for security - Fallback to ~/.timesafari if XDG paths fail - Add graceful degradation for SQLite failures - Allow app to boot even if SQLite initialization fails - Track and expose initialization errors via IPC - Add availability checks to all SQLite operations - Improve error reporting and logging - Security improvements - Set secure permissions (700) on data directories - Verify directory permissions on existing paths - Add proper error handling for permission issues TODO: - Fix database creation - Add retry logic for initialization - Add reinitialization capability - Add more detailed error reporting - Consider fallback storage options |
1 week ago |