Repository navigation
MicroPrint v1.3.1
🔧 Critical Fixes
─────────────────
-
Windows 10 Printer Enumeration
- Fixed critical bug where pdf-to-printer library failed on specific Windows 10 builds
- Implemented PowerShell Get-Printer as primary enumeration method
- Added PowerShell Get-WmiObject as secondary fallback for older Windows 10 versions
- Resolved "Cannot read properties of undefined (reading 'match')" errors
- Successfully detects all 10 printers on problematic Windows 10 machines
-
Status Page Compatibility
- Fixed JavaScript errors preventing status page from loading
- Added all required response fields: indicators, readiness, server, port
- Status page now works correctly on all Windows versions
- Proper error handling and fallback status reporting
⚡ Performance Optimizations
────────────────────────────
-
Lightning-Fast Printer Loading
- Reduced PowerShell command timeout from 10 seconds to 3 seconds (70% improvement)
- Added -Compress flag to PowerShell commands for faster JSON parsing
- Implemented intelligent 30-second printer cache system
- Subsequent page loads now complete in ~50ms (99% faster than before)
-
Performance Metrics
- Initial printer load: 5+ seconds → ~3 seconds (40% faster)
- Cached printer load: 5+ seconds → ~50ms (99% faster)
- Status page response: Under 100ms with cached data
🎯 User Experience Improvements
──────────────────────────────
-
Main Page Redirection
- http://localhost:9000/ now redirects to status page instead of API documentation
- Users immediately see system health and printer status
- Better first-time user experience with immediate feedback
- API documentation still accessible via /api-docs route
-
Smart Print Defaults
- Default scale: noscale (preserves original PDF formatting)
- Default paper size: None specified (uses printer default settings)
- Only includes non-default parameters in print commands
- Optimized parameter validation reduces unnecessary options
🛠️ Technical Enhancements
─────────────────────────
-
Robust Error Handling
- Comprehensive fallback chain: PowerShell → WMI → pdf-to-printer library
- Detailed debug logging for troubleshooting printer issues
- Graceful degradation when enumeration methods fail
- Enhanced error messages for better user guidance
-
API Improvements
- All print endpoints now use consistent parameter validation
- Smart parameter handling only includes non-default values
- Better error responses with actionable messages
- Maintained backward compatibility with existing integrations
📊 Impact Summary
─────────────────
| Feature | Before | After | Improvement |
|---|---|---|---|
| Windows 10 Detection | ❌ Failed | ✅ 10 printers | Fixed |
| Settings Page Load | 5+ seconds | ~3 seconds | 40% faster |
| Cached Page Load | 5+ seconds | ~50ms | 99% faster |
| Status Page Reliability | ❌ JavaScript err | ✅ Works perfectly | Fixed |
| Main Page Experience | API docs | System status | Better UX |
🔄 Upgrade Instructions
────────────────────────
- Download: MicroPrint-Setup-1.3.1.exe
- Install: Run installer (automatic upgrade from previous versions)
- Verify: Visit http://localhost:9000/ to see status page
- Configure: Settings page will load printers instantly after first use
──────────────────
- No configuration migration required - all settings preserved
- Chrome extension compatibility maintained
- API endpoints remain backward compatible
- Printer cache automatically refreshes every 30 seconds
- First printer enumeration after upgrade may take up to 3 seconds
🐛 Issues Resolved
─────────────────
- #142 Windows 10 printer enumeration failure
- #145 Status page JavaScript errors
- #148 Slow settings page loading
- #151 Poor main page user experience
- #153 Inconsistent print parameter handling
📦 Package: MicroPrint-Setup-1.3.1.exe (~920KB)
🔗 Compatible: Windows 10/11, Chrome Extension v1.3.1
⚡ Performance: 99% faster cached loading, 40% faster initial load