[PR #12212] [CLOSED] Add user-friendly error handling for port binding failures on Windows #44982

Closed
opened 2026-04-25 00:40:46 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/12212
Author: @lnorton89
Created: 9/7/2025
Status: Closed

Base: mainHead: windows-port-error-handling


📝 Commits (1)

  • 5162ad5 Add user-friendly error handling for port binding failures on Windows

📊 Changes

4 files changed (+220 additions, -1 deletions)

View changed files

📝 app/tray/wintray/tray.go (+13 -0)
📝 app/tray/wintray/w32api.go (+31 -0)
app/windows/msgbox.go (+73 -0)
📝 cmd/cmd.go (+103 -1)

📄 Description

PR adds a (basic) error dialog handling notification of port binding issues on Windows.

Fixes #12206

  • Added MessageBox functionality to the Windows tray API for showing GUI error dialogs
  • Enhanced server startup error handling to detect port binding failures with more comprehensive error detection
  • Implemented user-friendly error messages with clear instructions:
  • Explains that the port is in use
    • Provides two solutions (free up the port or change OLLAMA_HOST)
    • Includes a concrete example of how to change the port
  • Added wait for user input before closing to prevent silent failures

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/12212 **Author:** [@lnorton89](https://github.com/lnorton89) **Created:** 9/7/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `windows-port-error-handling` --- ### 📝 Commits (1) - [`5162ad5`](https://github.com/ollama/ollama/commit/5162ad550f7371e52d0680acc231a243eb2b41f5) Add user-friendly error handling for port binding failures on Windows ### 📊 Changes **4 files changed** (+220 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `app/tray/wintray/tray.go` (+13 -0) 📝 `app/tray/wintray/w32api.go` (+31 -0) ➕ `app/windows/msgbox.go` (+73 -0) 📝 `cmd/cmd.go` (+103 -1) </details> ### 📄 Description PR adds a (basic) error dialog handling notification of port binding issues on Windows. Fixes #12206 - Added MessageBox functionality to the Windows tray API for showing GUI error dialogs - Enhanced server startup error handling to detect port binding failures with more comprehensive error detection - Implemented user-friendly error messages with clear instructions: - Explains that the port is in use - Provides two solutions (free up the port or change `OLLAMA_HOST`) - Includes a concrete example of how to change the port - Added wait for user input before closing to prevent silent failures --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-25 00:40:46 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#44982