[GH-ISSUE #6074] [Issue]: Image generation timout and image génération size ignored in avatar génération at least #3367

Closed
opened 2026-10-21 06:02:23 +07:00 by bsakaguchi · 3 comments
Owner

Originally created by @Diudid on GitHub (Sep 12, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6074

Originally assigned to: @SpicyMarinara on GitHub.

Summary

Image génération for a OpenAI API compatible endpoint ignore configured Size and Timouts
i setup a localAI endpoint to mock openai endpoint and setup every image timout at 180000 sec.

Expected behavior

Image should be generated at 512x512 instead of 1024x 1024.
And these shoudl timout after more than 300 second when IMAGE_GEN_TIMEOUT_MS=1800000

Actual behavior

Size are ignored and images use non configured size values for generating and images.
Then is timout at 300 seconds, making the local image génération non working.

Steps to reproduce

  1. Configure a Image génération endpoint on openAI then setup url to point on compatible system, set it up in connection.
  2. Configure ENV to have :
    • PROVIDER_LOCAL_URLS_ENABLED=true
    • IMAGE_LOCAL_URLS_ENABLED=true
    • CHAT_GENERATION_TIMEOUT_MS=1800000
    • AGENT_CALL_TIMEOUT_MS=1800000
    • CUSTOM_TOOL_TIMEOUT_MS=300000
    • IMAGE_GEN_TIMEOUT_MS=1800000
    • GAME_DYNAMIC_IMAGE_PROMPT_TIMEOUT_MS=1800000
  3. Setup profile image generation size to 512x512
  4. make a personna profile, endpoint receive a request for a 1024x1024 image.

Environment

  • Marinara Engine version: v2.4.4
  • Install type: docker
  • OS + version: Fedora 44
  • Browser or app shell: Firefow/Librefox/chrome/chromium

Logs, screenshots, or video

Docker logs -f :
marinara-1 | {"level":50,"time":1789207506875,"pid":14,"hostname":"efb80cc580fc","err":{"type":"TypeError","message":"fetch failed: Headers Timeout Error","stack":"TypeError: fetch failed\ncaused by: HeadersTimeoutError: Headers Timeout Error\n at FastTimer.onParserTimeout [as _onTimeout] (/app/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h1.js:804:28)\n at Timeout.onTick [as _onTimeout] (/app/.pnpm/undici@7.29.0/node_modules/undici/lib/util/timers.js:162:13)\n at listOnTimeout (node:internal/timers:635:17)\n at process.processTimers (node:internal/timers:571:7)"},"msg":"Avatar generation failed"}
Body received by the image server:
{
"prompt": "High resolution, 2K, 4K, 8K, clear, good lighting, detailed, extremely detailed, sharp focus, intricate, beautiful, realistic+++, complementary colors, high quality, hyper-detailed, masterpiece, art station, stunning, centered face-and-shoulders portrait, Hair: Short brown hair, Green brown eyes\n\nDo not include: (worst quality, low quality:1.4), (low resolution, blurry, blur:1.2), jpeg artifacts, compression artifacts, poorly drawn, bad anatomy, wrong anatomy, deformed, mutated, disfigured, ugly, disgusting, text, watermark, signature, logo, username, artist name, (cartoon, anime, illustration, painting, drawing, sketch:1.3), 3d render, cgi, digital art, unrealistic, artificial, (deformed face, distorted face:1.3), asymmetrical face, crooked face, (bad teeth, yellow teeth, crooked teeth:1.2), unnatural smile, creepy smile, (dead eyes, lifeless eyes, doll eyes:1.3), crossed eyes, wall eyed, (plastic skin, waxy skin, smooth skin:1.2), poreless skin, airbrushed, (unnatural hair, plastic hair, helmet hair:1.1), bad hairline, facial asymmetry, misaligned features, uncanny valley, (overexposed, underexposed:1.2), harsh shadows on face, double chin (unless intended), neck too long, neck too short, (earrings mismatched, jewelry errors), floating accessories, (bad hands, poorly drawn hands, malformed hands:1.4), (wrong number of fingers, too many fingers, missing fingers:1.4), (fused fingers, merged fingers, webbed fingers:1.3), (extra fingers, fewer fingers, four fingers, six fingers:1.4), (deformed fingers, twisted fingers, bent fingers:1.2), (short fingers, long fingers, stubby fingers:1.1), (missing thumb, extra thumb, thumb wrong position:1.3), (fingernails wrong, no fingernails, long fingernails:1.1), (hands too small, hands too large, baby hands:1.2), floating hands, disembodied hands, hands in pockets poorly drawn, (asymmetrical eyes, uneven eyes, different sized eyes:1.3), (crossed eyes, lazy eye, wall eyed, strabismus:1.3), (dead eyes, empty eyes, soulless eyes, doll eyes:1.4), (no eye reflection, missing catchlight:1.2), (wrong eye color, mismatched eye colors:1.1), (iris bleeding, pupil wrong shape, square pupils:1.2), (double iris, multiple pupils:1.4), (eyelashes wrong, no eyelashes, too many eyelashes:1.1), (bloodshot eyes, yellow sclera:1.1) unless intended, glowing eyes, laser eyes, anime eyes, (bad anatomy, wrong anatomy, anatomical errors:1.3), (extra limbs, missing limbs, floating limbs:1.4), (extra arms, missing arms, three arms:1.4), (extra legs, missing legs, three legs:1.4), (body too long, torso too short, proportions wrong:1.2), (neck too long, giraffe neck, no neck:1.2), (shoulders uneven, shoulders too wide, shoulders too narrow:1.1), (waist distorted, hips wrong:1.1), (joints wrong, elbows backwards, knees backwards:1.3), contorted body, impossible pose, broken spine, body horror, mutation, extra body parts, logos, watermarks, borders, UI, collage layouts, duplicate faces, extra people, cropped-off heads.",
"n": 1,
"size": "1024x1024",
"model": "pornmaster_flux.2-klein-9b",
"response_format": "b64_json"
}

Additional context

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @Diudid on GitHub (Sep 12, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6074 Originally assigned to: @SpicyMarinara on GitHub. ## Summary Image génération for a OpenAI API compatible endpoint ignore configured Size and Timouts i setup a localAI endpoint to mock openai endpoint and setup every image timout at 180000 sec. ## Expected behavior Image should be generated at 512x512 instead of 1024x 1024. And these shoudl timout after more than 300 second when IMAGE_GEN_TIMEOUT_MS=1800000 ## Actual behavior Size are ignored and images use non configured size values for generating and images. Then is timout at 300 seconds, making the local image génération non working. ## Steps to reproduce 1. Configure a Image génération endpoint on openAI then setup url to point on compatible system, set it up in connection. 2. Configure ENV to have : - PROVIDER_LOCAL_URLS_ENABLED=true - IMAGE_LOCAL_URLS_ENABLED=true - CHAT_GENERATION_TIMEOUT_MS=1800000 - AGENT_CALL_TIMEOUT_MS=1800000 - CUSTOM_TOOL_TIMEOUT_MS=300000 - IMAGE_GEN_TIMEOUT_MS=1800000 - GAME_DYNAMIC_IMAGE_PROMPT_TIMEOUT_MS=1800000 3. Setup profile image generation size to 512x512 3. make a personna profile, endpoint receive a request for a 1024x1024 image. ## Environment - Marinara Engine version: v2.4.4 - Install type: docker - OS + version: Fedora 44 - Browser or app shell: Firefow/Librefox/chrome/chromium ## Logs, screenshots, or video Docker logs -f : marinara-1 | {"level":50,"time":1789207506875,"pid":14,"hostname":"efb80cc580fc","err":{"type":"TypeError","message":"fetch failed: Headers Timeout Error","stack":"TypeError: fetch failed\ncaused by: HeadersTimeoutError: Headers Timeout Error\n at FastTimer.onParserTimeout [as _onTimeout] (/app/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h1.js:804:28)\n at Timeout.onTick [as _onTimeout] (/app/.pnpm/undici@7.29.0/node_modules/undici/lib/util/timers.js:162:13)\n at listOnTimeout (node:internal/timers:635:17)\n at process.processTimers (node:internal/timers:571:7)"},"msg":"Avatar generation failed"} Body received by the image server: { "prompt": "High resolution, 2K, 4K, 8K, clear, good lighting, detailed, extremely detailed, sharp focus, intricate, beautiful, realistic+++, complementary colors, high quality, hyper-detailed, masterpiece, art station, stunning, centered face-and-shoulders portrait, **Hair:** Short brown hair, Green brown eyes\n\nDo not include: (worst quality, low quality:1.4), (low resolution, blurry, blur:1.2), jpeg artifacts, compression artifacts, poorly drawn, bad anatomy, wrong anatomy, deformed, mutated, disfigured, ugly, disgusting, text, watermark, signature, logo, username, artist name, (cartoon, anime, illustration, painting, drawing, sketch:1.3), 3d render, cgi, digital art, unrealistic, artificial, (deformed face, distorted face:1.3), asymmetrical face, crooked face, (bad teeth, yellow teeth, crooked teeth:1.2), unnatural smile, creepy smile, (dead eyes, lifeless eyes, doll eyes:1.3), crossed eyes, wall eyed, (plastic skin, waxy skin, smooth skin:1.2), poreless skin, airbrushed, (unnatural hair, plastic hair, helmet hair:1.1), bad hairline, facial asymmetry, misaligned features, uncanny valley, (overexposed, underexposed:1.2), harsh shadows on face, double chin (unless intended), neck too long, neck too short, (earrings mismatched, jewelry errors), floating accessories, (bad hands, poorly drawn hands, malformed hands:1.4), (wrong number of fingers, too many fingers, missing fingers:1.4), (fused fingers, merged fingers, webbed fingers:1.3), (extra fingers, fewer fingers, four fingers, six fingers:1.4), (deformed fingers, twisted fingers, bent fingers:1.2), (short fingers, long fingers, stubby fingers:1.1), (missing thumb, extra thumb, thumb wrong position:1.3), (fingernails wrong, no fingernails, long fingernails:1.1), (hands too small, hands too large, baby hands:1.2), floating hands, disembodied hands, hands in pockets poorly drawn, (asymmetrical eyes, uneven eyes, different sized eyes:1.3), (crossed eyes, lazy eye, wall eyed, strabismus:1.3), (dead eyes, empty eyes, soulless eyes, doll eyes:1.4), (no eye reflection, missing catchlight:1.2), (wrong eye color, mismatched eye colors:1.1), (iris bleeding, pupil wrong shape, square pupils:1.2), (double iris, multiple pupils:1.4), (eyelashes wrong, no eyelashes, too many eyelashes:1.1), (bloodshot eyes, yellow sclera:1.1) unless intended, glowing eyes, laser eyes, anime eyes, (bad anatomy, wrong anatomy, anatomical errors:1.3), (extra limbs, missing limbs, floating limbs:1.4), (extra arms, missing arms, three arms:1.4), (extra legs, missing legs, three legs:1.4), (body too long, torso too short, proportions wrong:1.2), (neck too long, giraffe neck, no neck:1.2), (shoulders uneven, shoulders too wide, shoulders too narrow:1.1), (waist distorted, hips wrong:1.1), (joints wrong, elbows backwards, knees backwards:1.3), contorted body, impossible pose, broken spine, body horror, mutation, extra body parts, logos, watermarks, borders, UI, collage layouts, duplicate faces, extra people, cropped-off heads.", "n": 1, "size": "1024x1024", "model": "pornmaster_flux.2-klein-9b", "response_format": "b64_json" } <!-- Paste relevant logs and add screenshots when possible --> ## Additional context <!-- Optional: related issue links, temporary workaround, etc. --> ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-10-21 06:02:23 +07:00
  • closed this issue
  • added the
    in-pr
    bug
    labels
Author
Owner

@Diudid commented on GitHub (Sep 12, 2026):

Seem like the avatar prompt is not sent to endpoint too. -> found the issue, lora setting likes <lora:name:multiplier> in the positive/negative prompt seem to remove the character prompt

<!-- gh-comment-id:5645351408 --> @Diudid commented on GitHub (Sep 12, 2026): Seem like the avatar prompt is not sent to endpoint too. -> found the issue, lora setting likes \<lora:name:multiplier\> in the positive/negative prompt seem to remove the character prompt
Author
Owner

@SpicyMarinara commented on GitHub (Sep 12, 2026):

SpicyMarinara is taking this issue with Codex assistance. I am tracing the shared image request path for configured dimensions and timeouts, plus the reported LoRA prompt truncation, and will keep the fix in one staging PR.

<!-- gh-comment-id:5646575456 --> @SpicyMarinara commented on GitHub (Sep 12, 2026): SpicyMarinara is taking this issue with Codex assistance. I am tracing the shared image request path for configured dimensions and timeouts, plus the reported LoRA prompt truncation, and will keep the fix in one staging PR.
Author
Owner

@SpicyMarinara commented on GitHub (Sep 12, 2026):

Fixed on staging by #6082. Image requests now honor the configured timeout through response headers and bodies, including local backend requests. Targeted timeout/provider regressions, pnpm check and the full CI matrix passed.

<!-- gh-comment-id:5647403476 --> @SpicyMarinara commented on GitHub (Sep 12, 2026): Fixed on staging by #6082. Image requests now honor the configured timeout through response headers and bodies, including local backend requests. Targeted timeout/provider regressions, pnpm check and the full CI matrix passed.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#3367
No description provided.