So, I went through and added the correct list of sizes and the scale per each size in the code, but I kept getting the error:

Here's how I modified the code:
#Author-Brian Ekins
#Description-Script will take a size 10 ring and iterate Size 5-12.5 with half-sizes in-between.
import adsk.core, adsk.fusion, traceback
import os
def run(context):
try:
app: adsk.core.Application = adsk.core.Application.get()
ui: adsk.core.UserInterface = app.userInterface
des: adsk.fusion.Design = app.activeProduct
# Get the parameter named "Scale".
scaleParam = des.allParameters.itemByName('Scale')
# Get the body named "Ring". This looks for it in the root component,
# this code will need to be modified if it's in a sub component.
root = des.rootComponent
body = root.bRepBodies.itemByName("Ring")
# List of name sizes and the associated scale factors.
sizeList = []
sizeList.append(('05.0', 0.79293))
sizeList.append(('05.5', 0.81313))
sizeList.append(('06.0', 0.83333))
sizeList.append(('06.5', 0.85354))
sizeList.append(('07.0', 0.87374))
sizeList.append(('07.5', 0.89394))
sizeList.append(('08.0', 0.91414))
sizeList.append(('08.5', 0.93434))
sizeList.append(('09.0', 0.95960))
sizeList.append(('09.5', 0.97980))
sizeList.append(('10.0', 1.00000))
sizeList.append(('10.5', 1.02020))
sizeList.append(('11.0', 1.04040))
sizeList.append(('11.5', 1.06061))
sizeList.append(('12.0', 1.08081))
sizeList.append(('12.5', 1.10101))
# Get the folder to export to from the user.
folderDialog = ui.createFolderDialog()
folderDialog.title = 'Specify Export Folder'
results = folderDialog.showDialog()
if results != adsk.core.DialogResults.DialogOK:
return
folder = folderDialog.folder
# Iterate through the sizes, scaling the model and exporting for each size.
for size in sizeList:
name = size[0]
scale = size[1]
# Modify the parameter to get the correct scale.
scaleParam.value = scale
# Give control back to Fusion so the view can refresh.
adsk.doEvents()
# Export the file as STEP.
exportMgr = des.exportManager
filename = os.path.join(folder, name + '.step')
stepOptions = exportMgr.createSTEPExportOptions(filename, root)
if exportMgr.execute(stepOptions):
WriteToTextWindow('Successfully exported ' + filename)
else:
WriteToTextWindow('Failed to export ' + filename)
except:
if ui:
ui.messageBox('Failed:\n{}'.format(traceback.format_exc()))
def WriteToTextWindow(text):
app = adsk.core.Application.get()
ui = app.userInterface
# Get the palette that represents the TEXT COMMANDS window.
textPalette = ui.palettes.itemById('TextCommands')
# Make sure the palette is visible.
if not textPalette.isVisible:
textPalette.isVisible = True
# Write the text.
textPalette.writeText(text)
And here's the parameter I set up. I set the unit as %, but for some reason it remains shows as blank in the list:
I'm not sure if this is an issue because I didn't initially build the rings using parameters, or if there's something more fundamental that I did wrong. Can you tell if this is a simple fix or if this isn't going to work?
On the off chance this just isn't going to work, I'm wondering if I'm approaching this the wrong way. Perhaps, instead of a script to build out the different sizes of each ring, maybe I can make one blank ring, and make fifteen copies of that blank ring that all reference the original, and resize them all to make sure they're the correct scale. Then, if I make a change to that original model, by putting a symbol into the face of it, all the other rings match it, and it's just a matter of getting a script to export all 16 rings to step files.
I know that when you start with a sketch and make a model, a change to the original sketch can trickle down to the model, but I can't remember how to ensure those changes come out in the end, and I can't remember if it's possible or how to do that with a finished model/body. Of course, it's possible I'm overthinking all of this. I tend to do that, come up with multiple solutions, and waste time trying to make them work instead of just working on my designs.