mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #5344] [Issue]: NovelAI image connection model dropdown shows too many models and fetch is broken #2952
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#2952
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ylli-selmani on GitHub (Aug 21, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/5344
Originally assigned to: @SpicyMarinara on GitHub.
Summary
For a NovelAI image connection, the model dropdown shows the entire app-wide image model catalog (every provider, not just NovelAI), and the "Fetch from API" button returns "Failed to fetch models: OK" instead of retrieving NovelAI's available models.
Expected behavior
The model dropdown should show only NovelAI-relevant models (nai-diffusion series). The "Fetch from API" button should either retrieve models from NovelAI's API or, if the API endpoint is not suitable for image model listing, not be shown for NovelAI connections at all.
Actual behavior
The dropdown populates with every model in IMAGE_GEN_MODELS from model-lists.ts, including models from unrelated providers (stability, grok, atlassc, etc.). Pressing "Fetch from API" hits the connection base URL with no path appended (because image_generation provider has an empty modelsEndpoint), which returns HTTP 200 with a plain text body of OK. JSON parse fails on that body, producing the error message "Failed to fetch models: OK".
Steps to reproduce
Environment
Marinara Engine diagnostics
Version: 2.4.4
Build: 2.4.4+6e7e85a7ba4a
Commit:
6e7e85a7baServer OS: Windows 10.0.26200 (x64)
Client OS: Windows 10.0
Browser / app shell: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:154.0) Gecko/20100101 Firefox/154.0
GPU: ANGLE (NVIDIA, NVIDIA GeForce GTX 980 Direct3D11 vs_5_0 ps_5_0), or similar
Active connection: NovelAI Image
Connection provider: image_generation
LLM model: nai-diffusion-5-full
Logs, screenshots, or video
Additional context
Root cause is two-fold:
The image_generation provider's modelsEndpoint is an empty string, so the generic fetch fallback builds the URL as just the base URL with nothing appended. The NovelAI image base URL (https://image.novelai.net) returns a plain OK body, which fails JSON parsing.
IMAGE_GEN_MODELS in model-lists.ts is a single flat array covering all image sources. The connection editor maps image_generation to this entire array via MODEL_LISTS[localProvider], with no filtering by the selected image source (unlike video generation, which filters by provider). So every image model from every source appears in the dropdown regardless of which image service is selected.
Note: NovelAI's OpenAI-compatible endpoint at /oa/v1/models exists but returns text models (xialong-v1, glm-4-6), not image models, so it cannot be used to populate the image model list. The fix is to filter the known-models catalog for NovelAI connections to nai- prefixed models and hide the fetch button for NovelAI, since there is no reliable API to fetch image model names from.
Template check
Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked: