mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #709] Persona & character native export drops fields and avatar image on round-trip #338
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#338
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 @LukaTheHero on GitHub (May 11, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/709
Originally assigned to: @LukaTheHero on GitHub.
Bug
Exporting a persona using the Marinara Native format and then importing it back loses the persona's profile picture, plus several other fields that are stored in the DB but not round-tripped.
Screenshot of the issue (imported persona showing default avatar):

The same problem exists for characters: exporting a character as Marinara Native and importing it back also strips the avatar image. (Compatible JSON is expected to omit the avatar — this is by design and is not changing.)
Fields lost during persona round-trip
Stripped at export (
buildNativePersonaEnvelope/buildCompatiblePersonaExport):avatarPath(and the actual image file is never embedded)Ignored at import (
importPersonainmarinara.importer.ts):commentpersonaStatsaltDescriptionstagssavedStatusOptionsavatarCrop(read but not embedded image data)Compatible JSON import (
ImportPersonaModal):nameColor,dialogueColor,boxColor,personaStats,altDescriptions,savedStatusOptions,avatarCropFields lost during character round-trip
Stripped at export (
buildNativeCharacterEnvelope):avatarPath(and the actual image file is never embedded into the JSON envelope — only/export-pngembeds it)Ignored at import (
importCharacter):Proposed fix
For Marinara Native format only (both personas and characters):
avatarfield on the envelope'sdata.avataris present, validate the image bytes, write todata/avatars/, and setavatarPathon the new row.comment,personaStats,altDescriptions,tags,savedStatusOptions).Compatible JSON exports stay avatar-less (as expected by spec).
PR
PR being opened by @LukaTheHero shortly.
Files involved
packages/server/src/routes/characters.routes.ts—buildNativePersonaEnvelope,buildCompatiblePersonaExport,buildNativeCharacterEnvelope, both export routespackages/server/src/services/import/marinara.importer.ts—importPersona,importCharacterpackages/client/src/components/modals/ImportPersonaModal.tsx— compatible JSON path field pass-through (minor)