[PR #6656] [MERGED] Fixed redirect check if direct URL is already Present #74479

Closed
opened 2026-05-05 06:34:21 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/6656
Author: @Tobix99
Created: 9/5/2024
Status: Merged
Merged: 9/5/2024
Merged by: @jmorganca

Base: mainHead: main


📝 Commits (1)

  • a72b666 Fixed if direct url is already present

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 server/download.go (+1 -1)

📄 Description

This is a fix regarding #6308 where the redirect check would fail with

unexpected status code 200.

The problem is, that if you try to pull a Model from an internal Registry, there would be no redirect, but the current logic expects at least one redirect. So i've added a the StatusCode 200 - OK to the check and return the Location of the redirect.

The bug was introduced with Pull#5962


🔄 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/6656 **Author:** [@Tobix99](https://github.com/Tobix99) **Created:** 9/5/2024 **Status:** ✅ Merged **Merged:** 9/5/2024 **Merged by:** [@jmorganca](https://github.com/jmorganca) **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (1) - [`a72b666`](https://github.com/ollama/ollama/commit/a72b666076c90e6ce2fa47277560977ac28c19f8) Fixed if direct url is already present ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `server/download.go` (+1 -1) </details> ### 📄 Description This is a fix regarding #6308 where the redirect check would fail with `unexpected status code 200`. The problem is, that if you try to pull a Model from an internal Registry, there would be no redirect, but the current logic expects at least one redirect. So i've added a the StatusCode 200 - OK to the check and return the Location of the redirect. The bug was introduced with [Pull#5962](https://github.com/ollama/ollama/pull/5962) --- <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-05-05 06:34:21 -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#74479