mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #6923] [Feature]: Macro variables improvement (history / state tracking) #3882
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#3882
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 @usagirei on GitHub (Oct 1, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6923
Originally assigned to: @SpicyMarinara on GitHub.
What problem does this solve?
Currently, macro variables are stored in the chat metadata table, inside a macroVariables field.
This makes it so that a new swipe or a deleted generation does not roll back the values and leaks state (there is no history).
If the user was using any of the variable macros - getvar, incvar, setvar, conditionals with if var.name, etc - and a message is deleted or regenerated, the value is not restored before generation, contrary to expectations.
Additionally, these values are not user accessible/visible.Already acessible in Chat settingsProposed solution
Alternatives considered
When the custom tracker capability is available:
Additional context
Example:
The user set up in a constantly activated lorebook entry for something to happen when a variable reaches zero, or decrease it by one otherwise, and made it such that a setvar macro was used elsewhere.
Regenerating the message multiple times will keep decreasing the counter and trigger the condition, instead of decreasing it only once - as the previous value was never restored
Template check
Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked: