#Active Effect Migration Exploration

1 messages · Page 1 of 1 (latest)

onyx kernel
#

First

queen kettle
#

Second

lime perch
#

When I run a safe configuration migration there are no errors at all. When I run it a second time after, weirdness ensued lol

#

somehow it turned the unavailables to passives for no reason, I think it was the original nones turned into passives

queen kettle
#

OK... well... slap that actor on the github issue I suppose? The before and after.

lime perch
#

well this ones actually the after after, its after you do a normal migration and then run the console command after that

queen kettle
#

Still.

queen kettle
#

So when I said "slap that actor on the github issue" I meant the exported json, not just pictures of it

vast warren
lime perch
queen kettle
#

@fallen hound

fallen hound
queen kettle
#

Thought you might be interested. 🙂

fallen hound
queen kettle
#

Make a backup, I'm sure Jeff would appreesh

fallen hound
#

how should I test it, overwrite the manifest link in system.json, unistall and install from manifest link, or is there a better option? (I have backups, destructive testing is perfectly fine)

lime perch
#

I have a seperate install that has been going back and forth on migration for the last 4 days lol

queen kettle
lime perch
#

I just plopped my live session world into the test bed and hit launch world, then load the backup and repeat

fallen hound
lime perch
#

I had wanted to test the migration when you completed it but nobody knew how to compile the system so we kinda figured we'd wait till you did

fallen hound
#

if this works there will be celebrations. I have scheduled a full day of migration and manual fixing with 109 tasks for tomorrow, that would be reduced to like 30 (containers and stuff)

lime perch
#

its probably definitely going to solve the core duplications but tim thought it wouldn't fix the dae/midi ones, we'll see in about 4 minutes when this completes

#

I really should take out the ddbi compendiums so this test process is faster lol

fallen hound
#

mine is running, too, but will probably take a bit longer -- despite running no automation (GM has was to much stuff in Compendiums...)

lime perch
#

It didn't fix midi/dae duplicates:

#

no errors at all, I did a safe configuration migration

#

Looks like it did fix the core dupe bug

#

Tim has his own script offered in DAE 11.3.3 that can be run and it checks various actors and removes the duplicates, he hasn't solved the issue of ones in compendiums yet cause thats alot more sensitive and most folks have their monsters in a shared compendium, thats on his todo list.

vast warren
lime perch
#

I think when you import a json actor, their ae's become unknown cause the UUID's don't match or something

#

in dae, you can run a command to fix the imported actors ae's before you migrate, I forge tthe command though

fallen hound
#

sadly have to report, did not work for our world either, and it did duplicate a hand made Lamp timer AE (so that one also nothing DDBimporter), neither Midi nor DAE ever installed for the world

#

Do you want the pre-migration exported actor?

#

restoring

#

the Items the AEs are on are DDBImporter created Items, the AEs are not

lime perch
#

my actors are also ddbi created

fallen hound
#

ddbimporter puts a lot of stuff on the item, but it is all in flags, and for me it does not create the AEs, this world never had DAE, and I created every of the AEs on that Actor by hand. I am not sure I created the Unarmed Defense below by hand btw.

#

also happens with all modules deactivated

fallen hound
# lime perch I think when you import a json actor, their ae's become unknown cause the UUID's...

ah, right, the origin won't match anymore, foundry isn't using (and keeping) GUIDs, right?, the UUIDs are just concatenations of IDs, that are only world-unique and need to be replaced on import, right? Also, they are (abused) as paths (or paths abused as IDs [path meaning entity parent/source - child information]).
all BS, the Items' IDs remain -- now the origin is UUID Item.AE, or...
oh, the origin is UUID starting with Actor, which does change on import

#

Yeah, so if origin is used testing with exported/imported Actors does not work

queen kettle
#

The embedded documents should be keeping their ids.

#

(items and effects)

fallen hound
# queen kettle (items and effects)

but the origin on the AE is a UUID with an Actor not existing after import -- and I think you are using the origin for something in migration

queen kettle
#

The migration script does not look at the actor's id, only the item's id. 🙂

#

Or specifically, the end of the uuid, so ignoring the Actor.<id> part.

queen kettle
#

I found a but

vast warren
queen kettle
#

Language! 😱

vast warren
fallen hound
#

okay, I will take a look, too, overdue having a look at how dnd5e does their/your/our migration scripts

fallen hound
#

aeh?? he has one effects and two on the sheet?

#

and I can delete both

#

ah, right, Actor.effect does no longer get all effects (which is ...)

#

restoring for next test...

#

so the migration does duplicate the Unarmored Defense, what do you @vast warren want me to check -- how do I see what was completed, don't see version numbers on the Actor (well, for ddbi, but don't see dnd5e version number)?

vast warren
fallen hound
vast warren
#

So if I (a) load 3.0.2, (b) create an actor and import the "Ketris Bearsmasher" information, (c) leave world, update to 3.0.3, (d) enter world, wait for migrations to run, then it removes the duplicate effects properly for me:

#

(before / after)

fallen hound
#

then, is there any branching in the migration script (of 3.0.3) that would be sensitive to starting version 2.4.max/3.0.2?

vast warren
#

Hmm, let me check something

fallen hound
#

are you aware of anyone not using ddbi having the problem? I mean, should not matter with everything deactivated, but at least one would have a good indication where to look in the data structure/ how it is read by the migration script

#

I'll have a look into the migration.mjs now, too, there is only one migration script in dnd5e, right?

vast warren
#

That's the only one

queen kettle
#

🤨

#

There is no way this should migrate correctly at all, one of them doesnt even have an origin

vast warren
queen kettle
#

Bearsmasher up there

vast warren
#

Hmm, looking at the raw JSON it definately does have an origin. In fact that is what that diff is saying, that one has origin and the other doesn't, otherwise it wouldn't appear in the diff

queen kettle
#

The one on the item does not have an origin

vast warren
#

Correct, because it is the origin

#

We only care about the origin of effects on the actor, to match them back to their original effect on the item

fallen hound
queen kettle
#

Ah - the origins do not have to match, it looks at the item id only

vast warren
#

¯\_(ツ)_/¯, Bearsmasher migrates perfectly for me, so I'm not sure where the problem is coming from

#

I did do another build of 3.0.3 which may or may not fix anything at all

queen kettle
#

wonder if something is getting changed during the export that muddies this 🤔

vast warren
#

To fix that, I'll just give you my mailing address and you can send your entire computer over to me for testing, nothing could be different then 🤪

fallen hound
vast warren
#

Just tested an imported Gial, also migrated properly

#

Can you try creating a fresh world and importing your own JSON to test? Make sure you create the world and import in 3.0.2 or earlier

fallen hound
queen kettle
fallen hound
#

should write a feature request to add the systemversion to the export

vast warren
fallen hound
vast warren
#

It is also added to a flag, flags.exportSource.systemVersion

fallen hound
#

without wanting to shoot myself into the foot: how many users are reporting problems? If I have to do the 109 tasks for migration I'll be pissed, but won't stop using FVTT

queen kettle
#

🤔

#

is this where we run a big, fat, diffObject on the actors, the one that failed and the one that succeeded

#

or rather, you do, since the "fix" (?) happens either during export or import 🤔 assuming it's not related to the world

fallen hound
queen kettle
#

Not really sure. 🙂

vast warren
#

I'd say import in 2.4.1 or 3.0.2 and do a diff before migration foundry.utils.diffObject(actorA.toObject(), actorB.toObject())

fallen hound
#

just getting some coffein before that

queen kettle
#

$5 says it's something stupid and the fix is 1 line of code. always is.

fallen hound
queen kettle
#

Thanks!

fallen hound
vast warren
fallen hound
#

this will take a while -- empty Gial world migration is somewhat faster than real world oversized with assets

#

when did you @vast warren release the 2nd 3.0.3 version, and what did you change? both gials are okay! (ketris, too, all seems fine)

queen kettle
#

50 mins ago

fallen hound
#

... why don't I just look at the commit..

#

which branch is it?

vast warren
#

I modified slightly how it checks version number to ensure the migration ran correctly

fallen hound
#

okay, thanks a lot -- tomorrow only adopting new features related migration work, not fixing bugged ones. 🥳

eternal robin
vast warren
eternal robin
eternal robin
#

I did notice that for unlinked tokens with effects to remove that the following error is thrown:
actor.mjs:3124 Uncaught (in promise) TypeError: Cannot read properties of null (reading 'visible')
at Actor5e._displayTokenEffect (actor.mjs:3124:26)
at Actor5e._onUpdate (actor.mjs:3079:10)
at ActorDelta._onUpdate (foundry.js:18542:25)
at ClientDatabaseBackend.callback (foundry.js:13738:11)
at foundry.js:13712:43
at Array.map (<anonymous>)
at #handleUpdateDocuments (foundry.js:13712:33)
at async Actor5e.updateDocuments (commons.js:8001:23)
at async Actor5e.update (commons.js:8098:23)
at async migrateWorld (migration.mjs:119:11)

eternal robin
lime perch
vast warren