[PR #15254] [MERGED] model/parsers: fix gemma4 arg parsing when quoted strings contain " #15093

Closed
opened 2026-04-13 01:10:11 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/15254
Author: @drifkin
Created: 4/3/2026
Status: Merged
Merged: 4/3/2026
Merged by: @drifkin

Base: mainHead: drifkin/gemma-4-quotes


📝 Commits (3)

  • 6fa035e model/parsers: fix gemma4 arg parsing when quoted strings contain "
  • db367c3 add more tests, be careful about what we escape
  • 73a8e9d fix backslash-quote case, it really should be a literal backslash

📊 Changes

2 files changed (+270 additions, -6 deletions)

View changed files

📝 model/parsers/gemma4.go (+64 -6)
📝 model/parsers/gemma4_test.go (+206 -0)

📄 Description

Fixes: #15241


🔄 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/15254 **Author:** [@drifkin](https://github.com/drifkin) **Created:** 4/3/2026 **Status:** ✅ Merged **Merged:** 4/3/2026 **Merged by:** [@drifkin](https://github.com/drifkin) **Base:** `main` ← **Head:** `drifkin/gemma-4-quotes` --- ### 📝 Commits (3) - [`6fa035e`](https://github.com/ollama/ollama/commit/6fa035edd5350cd833f09a0962ba573eab83cd2d) model/parsers: fix gemma4 arg parsing when quoted strings contain " - [`db367c3`](https://github.com/ollama/ollama/commit/db367c33cf39631823f38be0ff2a85a268539383) add more tests, be careful about what we escape - [`73a8e9d`](https://github.com/ollama/ollama/commit/73a8e9d62c8cec6a32f363d92cdd43a06a5faf1c) fix backslash-quote case, it really should be a literal backslash ### 📊 Changes **2 files changed** (+270 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `model/parsers/gemma4.go` (+64 -6) 📝 `model/parsers/gemma4_test.go` (+206 -0) </details> ### 📄 Description Fixes: #15241 --- <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-13 01:10:11 -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#15093