Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix: Duplication of module contents after saving with module running on multiple loaded profiles#7572

Merged
vadi2 merged 3 commits intoMudlet:developmentfrom
patrickvinas:fix-module-duplication
Dec 21, 2024
Merged

Fix: Duplication of module contents after saving with module running on multiple loaded profiles#7572
vadi2 merged 3 commits intoMudlet:developmentfrom
patrickvinas:fix-module-duplication

Conversation

@patrickvinas
Copy link
Contributor

Brief overview of PR changes/additions

Remove duplicate writes from reloadModule() function. The editing profile writes to the module (in saveProfile function), and then reloadModule uninstalls and reinstalls the module in all the other open profiles. Writing the module xml again in the other open profiles causes the duplication.

Motivation for adding to Mudlet

To fix the duplication bug in modules

Other info (issues closed, discussion etc)

Closes issue 7484
/claim #7484

@patrickvinas patrickvinas requested a review from a team as a code owner December 19, 2024 03:52
@add-deployment-links
Copy link

add-deployment-links bot commented Dec 19, 2024

Hey there! Thanks for helping Mudlet improve. 🌟

Test versions

You can directly test the changes here:

No need to install anything - just unzip and run.
Let us know if it works well, and if it doesn't, please give details.

@algora-pbc
Copy link

algora-pbc bot commented Dec 19, 2024

💵 To receive payouts, sign up on Algora, link your Github account and connect with Stripe.

@techjoec
Copy link

tested here with 8 profiles, 3 marked to sync on MULTIPLE AT ONCE....And I can no longer reproduce the issue!!! Thank you! Hopefully others can test as well and get the same result!!

Copy link
Member

@vadi2 vadi2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for tackling this!

Does module sync still work in this PR? The code in question was introduced as part of #5475

@patrickvinas
Copy link
Contributor Author

Module sync does indeed still work. I tested with 3 open profiles, each with 5 modules set to sync, and @techjoec tested with 8 open profiles (4 of which had sync enabled). Changes replicated across all profiles immediately, from any sync-enabled profile.

@techjoec
Copy link

Yes I tried a few different edits and configurations with 3 modules marked to sync on one and many profiles, sync seems to work fine (better, in fact).

@techjoec
Copy link

Reading that PR, I see folks mention nested images and files. I don't have any of that going on so perhaps someone else can test having assets included or such? My modules are .mpackages i exported from mudlet itself with just triggers/aliases/scripts within.

Copy link
Member

@vadi2 vadi2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, glad to hear its working 👍

@vadi2 vadi2 merged commit f08512c into Mudlet:development Dec 21, 2024
10 checks passed
@patrickvinas patrickvinas deleted the fix-module-duplication branch December 21, 2024 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants