Troubleshooting
This section provides solutions to common issues and errors encountered while using the Portfolio and Options Tracker.
Installation and Setup Issues
Dependency Installation Problems
- Issue: Error installing required packages with pip
- Solution:
- Ensure you’re using Python 3.7 or higher
- Try upgrading pip:
pip install --upgrade pip - Install packages individually if batch installation fails
- Consider using a virtual environment to avoid conflicts
Application Won’t Start
- Issue: Python script fails to launch or crashes immediately
- Solution:
- Verify all dependencies are correctly installed
- Check Python version compatibility
- Ensure you’re running from the correct directory
- Look for error messages in the terminal/command prompt
Stock Trading Issues
Cannot Buy Stocks
- Issue: “Insufficient funds” error when attempting to purchase stocks
- Solution:
- Verify you have enough cash in your account balance
- Add cash using the “Cash Management” section before purchasing
- Check that purchase amount (shares × price) doesn’t exceed available cash
Stock Prices Not Updating
- Issue: Prices appear outdated or don’t refresh
- Solution:
- Check your internet connection
- Verify the stock ticker symbol is correct and supported by Yahoo Finance
- Try refreshing the portfolio view
- Some stocks may have delayed pricing outside market hours
Cannot Sell Stocks
- Issue: Error when attempting to sell shares
- Solution:
- Ensure you own the number of shares you’re trying to sell
- Check that shares aren’t tied up in covered call contracts (only “available” shares can be sold)
- Verify the stock ticker is entered correctly
Options Trading Issues
Cannot Create Covered Call
- Issue: Error when trying to add a covered call position
- Solution:
- Verify you have exactly 100 or more available (non-contracted) shares of the target stock
- Ensure the stock ticker matches exactly with your holdings
- Check that the expiration date is in the future and in YYYY-MM-DD format
- Confirm strike price and premium are entered as valid numbers
Options Not Expiring Automatically
- Issue: Expired options remain in the system
- Solution:
- Ensure your system date and time are correct
- Restart the application to trigger expiration processing
- Verify the expiration date was entered correctly in YYYY-MM-DD format
- Check that system clock is set to correct timezone
Manual Exercise Not Working
- Issue: “Call Away” button doesn’t work
- Solution:
- Confirm the option position exists and is active
- Verify you have the correct number of shares in the contract
- Check that the option hasn’t already been exercised or expired
Data and File Issues
Data Not Saving
- Issue: Changes don’t persist between sessions
- Solution:
- Check file permissions in the application directory
- Ensure you have write access to the folder
- Verify data files aren’t marked as read-only
- Run application with appropriate permissions
Missing Data Files
- Issue: Application can’t find portfolio.txt, cash.txt, or other data files
- Solution:
- Files are created automatically on first run
- Ensure you’re running the application from the correct directory
- Check if files were accidentally deleted or moved
- Application will recreate missing files with default values
Corrupted Data Files
- Issue: Application fails to load existing data
- Solution:
- Backup existing data files
- Try opening data files in a text editor to check for formatting issues
- Restore from backup if available
- Clear problematic entries manually from the text files
Dividend Tracking Issues
Dividends Not Detected Automatically
- Issue: Known dividends aren’t appearing in the system
- Solution:
- Check internet connection for dividend data retrieval
- Verify you owned the stock before the ex-dividend date
- Some dividend data may be delayed; try restarting the application later
- Add dividends manually using the dividend tracking section if automatic detection fails
Missing Historical Dividends
- Issue: Past dividends aren’t being credited
- Solution:
- Historical recovery only covers the past 6 months
- Manually add older dividends using the dividend tracking interface
- Verify stock ownership dates align with ex-dividend dates
- Check that dividend amounts and dates are accurate
User Interface Issues
Theme Not Changing
- Issue: Dark/light theme toggle doesn’t work
- Solution:
- Restart the application after changing themes
- Ensure sv_ttk theme package is properly installed
- Try closing and reopening the application
Display or Layout Problems
- Issue: Text is cut off or interface elements are misaligned
- Solution:
- Try resizing the application window
- Check system display scaling settings
- Ensure you’re using a supported screen resolution
- Restart the application to reset the interface
Performance Issues
Slow Loading or Updates
- Issue: Application is sluggish or takes time to update
- Solution:
- Check internet connection speed for market data retrieval
- Close other applications to free up system resources
- Consider the number of positions - large portfolios may take longer to update
- Restart the application periodically to clear memory
Application Freezing
- Issue: Application becomes unresponsive
- Solution:
- Close the application and restart
- Check system resources and available memory
- Verify internet connection is stable
- Look for error messages that might indicate the cause
Network Connectivity Issues
No Internet Connection Errors
- Issue: Cannot retrieve stock prices or dividend data
- Solution:
- Verify internet connection is working
- Check firewall settings that might block the application
- Try using a different network connection
- Some corporate networks may block financial data APIs
Yahoo Finance API Issues
- Issue: Stock data retrieval fails
- Solution:
- Check if Yahoo Finance is experiencing service issues
- Try again later as API issues are usually temporary
- Verify stock ticker symbols are correct and supported
- Some delisted or inactive stocks may not have data available
General Troubleshooting Steps
First Steps for Any Issue
- Check internet connection
- Restart the application
- Ensure all dependencies are up to date
- Verify system date and time are correct
- Check that data files aren’t corrupted or missing
When to Report Issues
If problems persist after trying these solutions, please report the issue with:
- Detailed description of the problem
- Steps to reproduce the issue
- Error messages (if any)
- Your operating system and Python version
- Screenshot of the problem (if applicable)
Emergency Data Recovery
If critical data is lost:
- Check for backup files in the application directory
- Look for temporary files that might contain recent data
- Restore from your personal backups of the data files
- Contact support with details about the data loss incident