Port and Network Issues
Port Already in Use
Problem: When starting Markdown-OS, you see an error about port availability. Cause: Another application is using the requested port. Solution: Markdown-OS automatically handles this by incrementing to the next available port. Check the console output to see which port was selected:The auto-increment feature searches from your specified port up to 65535. If you want to force a specific port, first stop the application using that port.
No Available Ports
Problem: Error message: “No available TCP port found in range 8000-65535.” Cause: All ports from your start port to 65535 are occupied (extremely rare). Solution:Invalid Port Number
Problem: Error: “Start port must be between 1 and 65535.” Cause: Port number is outside the valid range. Solution: Use a port between 1 and 65535:Ports below 1024 typically require administrator/root privileges. It’s recommended to use ports 8000 and above for local development.
Cannot Access from Remote Machine
Problem: Server runs locally but cannot be accessed from another machine on the network. Cause: Server is bound to127.0.0.1 (localhost only).
Solution:
Bind to 0.0.0.0 to accept connections from all interfaces:
Browser Doesn’t Auto-Open
Problem: Server starts but browser doesn’t open automatically. Cause: This is normal in headless environments (cloud VMs, SSH sessions, containers). Solution: Manually open the URL shown in the console output:In cloud VMs, you may see harmless dbus errors in the logs like:These can be safely ignored - the server is working correctly.
File and Path Issues
File Does Not Exist
Problem: Error: “File does not exist: /path/to/file.md” Cause: The specified path doesn’t exist. Solution:Path Is Not a File/Directory
Problem: Error: “Path is not a file” or “Path is not a directory” Cause: You’re trying to open a special file (socket, device, etc.) or there’s a file/directory type mismatch. Solution: Ensure you’re opening a regular markdown file or directory:Unsupported File Type
Problem: Error: “Only markdown files are supported (.md, .markdown).” Cause: File extension is not.md or .markdown.
Solution:
Use a markdown file:
Directory Contains No Markdown Files
Problem: Error: “Directory contains no markdown files (.md, .markdown)” Cause: The directory (including all subdirectories) has no.md or .markdown files.
Solution:
Permission Denied
Problem: Cannot read or write files. Cause: Insufficient file system permissions. Solution: Check and fix permissions:Installation and Dependency Issues
Command Not Found
Problem:markdown-os: command not found
Cause: Package not installed or not in PATH.
Solution:
Wrong Python Version
Problem: Import errors or syntax errors on startup. Cause: Python version is below 3.11 (project specifies Python 3.13 in.python-version).
Solution:
Install the correct Python version with uv:
Missing Dependencies
Problem: Import errors for packages likefastapi, typer, etc.
Cause: Dependencies not installed.
Solution:
pyproject.toml and uv.lock and installs all required dependencies.
Editor and UI Issues
Changes Not Saving
Problem: Edits don’t persist to disk. Possible Causes:File lock conflict
File lock conflict
Another process may have the file locked.Solution: Close other applications that might be accessing the file. Markdown-OS creates
.md.lock files for synchronization - these are temporary and should be automatically removed.Permission issues
Permission issues
Solution: Ensure you have write permissions:
Network/WebSocket disconnected
Network/WebSocket disconnected
Solution: Check browser console for errors. Refresh the page to re-establish the connection.
External Changes Not Detected
Problem: File changed outside the editor but UI doesn’t update. Cause: WebSocket connection dropped or file watcher not working. Solution:Conflict Modal Appears
Problem: Dialog showing “File was modified externally” with options to save/discard/cancel. Cause: The file was changed by another program while you have unsaved changes in the editor. Solution: This is expected behavior - Markdown-OS is protecting you from data loss. Choose an option:- Save My Changes - Overwrites the external changes with your edits
- Discard My Changes - Loads the external version, losing your edits
- Cancel - Keeps the modal open so you can copy your changes elsewhere
If you see this frequently, you may have another auto-save system (like a cloud sync tool) conflicting with Markdown-OS.
Images Not Loading
Problem: Uploaded images don’t display. Cause: Images not saved correctly or path issues. Solution:Check image location
Images are saved to an
images/ directory:- File mode:
images/adjacent to the markdown file - Folder mode:
images/in the workspace root
Mermaid Diagrams Not Rendering
Problem: Mermaid code blocks show as plain text. Cause: Invalid Mermaid syntax or JavaScript error. Solution:Check syntax
Use the Mermaid Live Editor (https://mermaid.live) to validate your diagram syntax.
Performance Issues
Slow Loading in Folder Mode
Problem: File tree takes a long time to load. Cause: Very large directory with many files. Solution:Open a subdirectory instead
Open a subdirectory instead
Use file mode for single files
Use file mode for single files
High CPU Usage
Problem: Server process consuming significant CPU. Cause: File watcher polling many files or frequent external changes. Solution:- Exclude the workspace from other file watchers (IDEs, cloud sync tools)
- Close unnecessary tabs in folder mode (limit is 15 tabs)
- Use file mode instead of folder mode when working on a single file
Getting Help
If you encounter an issue not covered here:- Check the console output for specific error messages
- Review the browser DevTools console (F12) for JavaScript errors
- Report issues at: https://github.com/anomalyco/opencode
When reporting issues, include:
- Full error message from console
- Command you ran
- Operating system and Python version
- Output of
uv --version