I'm working on a sheet upgrade script (still...<sigh>) and am having problem with setAttrs not working 100% correctly and wondering: a) is anyone else seeing this problem, and b) what am I doing wrong...? Here's my sheet worker: function convertRS (originSection, destinationSection, ofieldArray, dfieldArray, daddlfieldArray, defaultValues) { /*------ example of call ------ || originSection = section (without repeating_) fields will be migrated FROM || destinationSection = section (without repeating_) fields will be migrated TO || ofieldArray = Array of Fields that need to be migrated || dfieldArray = Array of Fields the ofieldArray will be mapped to || NOTE: The number of fields in the ofieldArray and dfieldArray should be the same || daddlfieldArray = Additional fields in the destination section that may not be in the original section || defaultValues = Default values for list of fields in daddlfieldArray || NOTE: The number of fields in the daddlfieldArray and defaultValues should be the same || || Example: || var hindranceFields = ["hindrance","hindrancedescription"]; || convertRS("mhindrances","hindrances",hindranceFields,hindranceFields); --------*/ console.log("originSection: " + originSection); console.log("destinationSection: " + destinationSection); console.log("ofieldArray: " + ofieldArray); console.log("dfieldarray: " + dfieldArray); console.log("Number of Entries in ofieldArray: " + ofieldArray.length); console.log("Number of Entries in dfieldArray: " + dfieldArray.length); let originRS = "repeating_"+originSection; getSectionIDs(originRS, function(idArray) { if (idArray.length > 0) { console.log("originSection IDs: " + idArray); let oldAttrs = []; for (let a=0; a < idArray.length; a++) { for (let b=0; b < ofieldArray.length; b++) { oldAttrs[oldAttrs.length] = originRS + "_" + idArray[a] + "_" + ofieldArray[b]; } } getAttrs(oldAttrs, function(v) { let sattrs = {}; for(let i=0; i < idArray.length; i++) { let newrowid = generateRowID(); console.log("~~~~ ConvertRS Iteration " + i + ":: for Section: "+ originSection + ":: id generated: " + newrowid +" ~~~~"); let originRF = "repeating_" + originSection + "_" + idArray[i] + "_"; let destinationRF = "repeating_" + destinationSection + "_" + newrowid + "_"; //migrate original fields to new fields for(var r=0; r < ofieldArray.length; r++) { let getORF = '', putdestinationRF = ''; console.log("********************"); console.log("** originRF: "+originRF+ofieldArray[r]); console.log("** destinationRF: "+destinationRF+dfieldArray[r]); console.log("********************"); getORF = originRF+ofieldArray[r]; console.log(i+"-"+r+") Current value of getORF: "+getORF+": "+v[getORF]); putdestinationRF = destinationRF+dfieldArray[r]; sattrs[putdestinationRF]=v[getORF]; } //Check to see if we need to set any default values if (daddlfieldArray.length > 0 && daddlfieldArray.length === defaultValues.length) { console.log("!! Need to set some additional fields !!"); //Set default value for other fields for(let r=0; r < daddlfieldArray.length; r++) { let getORF = '', putdestinationRF = ''; console.log("********************"); console.log("** destinationRF: "+destinationRF+daddlfieldArray[r]); console.log("********************"); putdestinationRF = destinationRF+daddlfieldArray[r]; sattrs[putdestinationRF] = defaultValues[r]; } } else { console.log("!! No additional fields to set OR the number of fields doesn't match the number of values !!"); } } console.log("##### sattrs: " + JSON.stringify(sattrs) + " #####"); setAttrs(sattrs, {silent: true}); }); } else { console.log("<===== "+originSection+" had no rows =====>"); } }); } When I upgrade the sheet, I get this in the console... ##### sattrs: {"repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weapon":"Colt Army (.44) x2","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_range":"12/24/48","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_rof":"1","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgnumdice":"2","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgdietype":"d6!","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgbonusnum":"2","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponweight":"4","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponnotes":"GSoD: +1 dmg; Shots: 6; Single-Action","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_damageatt":"na","repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponcarried":"on","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weapon":"Winchester '73 (.44)","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_range":"24/48/96","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_rof":"1","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgnumdice":"2","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgdietype":"d8!","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgbonusnum":"1","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponweight":"7","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponnotes":"GSoD: +1 dmg; Shots: 15; AP 2","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_damageatt":"na","repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponcarried":"on","repeating_weapons_-LXYYz4j2omEYsuh6BuG_weapon":"Dbl Barrel Shotgun","repeating_weapons_-LXYYz4j2omEYsuh6BuG_range":"12/24/48","repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgnumdice":"2","repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgdietype":"d6!","repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgbonusnum":"1","repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponweight":"8","repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponnotes":"GSoD: +1 dmg; Shots: 2; +2 Shooting Rolls","repeating_weapons_-LXYYz4j2omEYsuh6BuG_damageatt":"na","repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponcarried":"on"} ##### and... ##### sattrs: {"repeating_weapons_-LXYYz4QPMvMb84JLXrf_weapon":"Brass Knuckles","repeating_weapons_-LXYYz4QPMvMb84JLXrf_dmgnumdice":"1","repeating_weapons_-LXYYz4QPMvMb84JLXrf_dmgbonusnum":"1","repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponweight":"1","repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponnotes":"GSoD: +1 dmg","repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponcarried":"on","repeating_weapons_-LXYYz4UjZHr59qveESU_weapon":"Bowie Knife","repeating_weapons_-LXYYz4UjZHr59qveESU_dmgnumdice":"1","repeating_weapons_-LXYYz4UjZHr59qveESU_dmgbonusnum":"2","repeating_weapons_-LXYYz4UjZHr59qveESU_weaponweight":"2","repeating_weapons_-LXYYz4UjZHr59qveESU_weaponnotes":"AP 1; GSoD: +1 dmg","repeating_weapons_-LXYYz4UjZHr59qveESU_weaponcarried":"on","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weapon":"Saber","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgnumdice":"1","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgdietype":"6!","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgbonusnum":"1","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponweight":"5","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponnotes":"GSoD: +1 dmg","repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponcarried":"on"} ##### Made easier to read: { "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weapon": "Colt Army (.44) x2", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_range": "12/24/48", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_rof": "1", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgnumdice": "2", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgdietype": "d6!", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_dmgbonusnum": "2", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponweight": "4", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponnotes": "GSoD: +1 dmg; Shots: 6; Single-Action", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_damageatt": "na", "repeating_weapons_-LXYYz4ay-fSFk1SfjKj_weaponcarried": "on", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weapon": "Winchester '73 (.44)", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_range": "24/48/96", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_rof": "1", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgnumdice": "2", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgdietype": "d8!", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_dmgbonusnum": "1", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponweight": "7", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponnotes": "GSoD: +1 dmg; Shots: 15; AP 2", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_damageatt": "na", "repeating_weapons_-LXYYz4eOd5LpvgYk4t9_weaponcarried": "on", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_weapon": "Dbl Barrel Shotgun", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_range": "12/24/48", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgnumdice": "2", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgdietype": "d6!", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_dmgbonusnum": "1", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponweight": "8", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponnotes": "GSoD: +1 dmg; Shots: 2; +2 Shooting Rolls", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_damageatt": "na", "repeating_weapons_-LXYYz4j2omEYsuh6BuG_weaponcarried": "on" } and... { "repeating_weapons_-LXYYz4QPMvMb84JLXrf_weapon": "Brass Knuckles", "repeating_weapons_-LXYYz4QPMvMb84JLXrf_dmgnumdice": "1", "repeating_weapons_-LXYYz4QPMvMb84JLXrf_dmgbonusnum": "1", "repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponweight": "1", "repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponnotes": "GSoD: +1 dmg", "repeating_weapons_-LXYYz4QPMvMb84JLXrf_weaponcarried": "on", "repeating_weapons_-LXYYz4UjZHr59qveESU_weapon": "Bowie Knife", "repeating_weapons_-LXYYz4UjZHr59qveESU_dmgnumdice": "1", "repeating_weapons_-LXYYz4UjZHr59qveESU_dmgbonusnum": "2", "repeating_weapons_-LXYYz4UjZHr59qveESU_weaponweight": "2", "repeating_weapons_-LXYYz4UjZHr59qveESU_weaponnotes": "AP 1; GSoD: +1 dmg", "repeating_weapons_-LXYYz4UjZHr59qveESU_weaponcarried": "on", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weapon": "Saber", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgnumdice": "1", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgdietype": "6!", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_dmgbonusnum": "1", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponweight": "5", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponnotes": "GSoD: +1 dmg", "repeating_weapons_-LXYYz4XdTWWLFrvA4KS_weaponcarried": "on" } It areas in bold, are where the problem exists...in the case of the first, not all the data is written correctly (I'll try post a screen sheet after I save this...don't want to lose everything I've written...), and in the case of the second, the brass knuckles show up, but the other two weapons aren't there at all. There are some fields missing from the Brass Knuckles, too--like the damage die type, but given that it's a d4, it's very likely the origin field was just a default value...so, perhaps there's "nothing" for the sheet worker to grab? Thoughts on what the problem may be? Here's what the character sheet entry looks like after the sheet worker executes: Here's the source (two images, because I'm taking two different repeating sections and combining them into a single one: I'll try a reply to get the other images in...(I hate trying to get images in forum posts...I waste more time doing it...:-/) Edit: I give up...needless to say, the damage should be strength 2 d6 + 0 for the Dbl Barrel Shotgun. For the brass knuckles, there should be a 1 after the 1d4, but more importantly, there should be two more weapons after it (Saber and Bowie knife).