Trouble recalling track presets via script
Title
Trouble recalling track presets via script
What do you expect to happen when you run the script/macro?
Recall a track preset in Pro Tools
Are you seeing an error?
15.04.2025 18:18:07.70 [EditorWindow:Renderer]: Active Focus Container: commandsPage/commands Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:08.08 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:08.09 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:08.09 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:08.10 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:08.14 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:09.73 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:09.74 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:09.81 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:09.84 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:11.29 [EditorWindow:Renderer]: Active Focus Container: commandsPage/commands Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:13.83 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:14.97 [EditorWindow:Renderer]: User Data Store data changed Line 56036 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:14.97 [EditorWindow:Renderer]: Updating User Settings. officialPackages= 7 Line 56119 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:14.99 [EditorWindow:Renderer]: Invalid version: {"min":"SoundFlow 5.8.1"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:14.99 [EditorWindow:Renderer]: Package Sparrow MIDI Faders from Lee K Martin has set SF version to >= 'SoundFlow 5.8.1' [EditorWindow:Renderer]: Package DADman from Keeley has set SF version to >= '5.04' [EditorWindow:Renderer]: Invalid version: {"min":"5.04"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js 15.04.2025 18:18:15.09 [Backend]: [SF_FIREBASE_WS]: Received 3103 bytes. Total received: 128784
15.04.2025 18:18:15.09 [Backend]: [RunCommandNode::Deserialize] Macro has a RunCommandNode with commandId 'user:cli50xtc200015210vyksy31z:clik0aumb0018y510wqhabfnv#clik0opvm002cy510n07kmaa0', which could not be resolved
15.04.2025 18:18:15.09 [Backend]: [ConfigurationController] LoadConfigurationAsync user 'zidcniFSLhRbSKJI4WnurSPSZfJ3' effective changeType 'ScriptSource' reason 'SetJson' changedPath '/customCommandPackages/cm9htimyr0000cj102py228sv/commands/cm9j8kyg8000eda10a60hlgsc/source' hasCloudPro: True:
[ConfigurationController] Could not patch script source, falling back to re-reading configuration from scratch
Effective Active User Profile: default
15.04.2025 18:18:15.09 [Backend]: [SF_FIREBASE_WS]: Received 44 bytes. Total received: 128828
15.04.2025 18:18:15.09 [EditorWindow:Renderer]: User Data Store data changed Line 56036 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:15.09 [EditorWindow:Renderer]: Updating User Settings. officialPackages= 7 Line 56119 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Invalid version: {"min":"SoundFlow 5.8.1"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Invalid version: {"min":"5.04"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Package Sparrow MIDI Faders from Lee K Martin has set SF version to >= 'SoundFlow 5.8.1' <= 'undefined' Line 550896 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Package DADman from Keeley has set SF version to >= '5.04' <= 'undefined' Line 550896 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:20.09 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:20.09 [EditorWindow:Renderer]: Calling backendwebclient sendasync: /commands/run [object Object] Line 56597 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:20.09 [Backend]: Received run command: user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc
15.04.2025 18:18:20.09 [Backend]: >> Command: test track preset [user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc]
[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'
15.04.2025 18:18:20.09 [Backend]: NSArray.ArrayFromHandle count = 1
15.04.2025 18:18:20.09 [Backend]: [ServerController] Running command from sfgui: 'test track preset' (user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc)
15.04.2025 18:18:20.20 [Backend]: Mouse current pos is: (921.97265625, 337.375)
Clicking with mouse here: (10, 60)
15.04.2025 18:18:20.21 [Backend]: Moving mouse back to: (921.97265625, 337.375)
15.04.2025 18:18:20.21 [Backend]: Position is now: (921.97265625, 337.375)
15.04.2025 18:18:20.23 [Backend]: ProTools version: 24.10.2.205 class: PT2024_10
ProTools processID: 1068
15.04.2025 18:18:20.23 [Backend]: Pro Tools language: English
15.04.2025 18:18:20.26 [Backend]: [LOG] Target track selected: Hits_FX Stinger
15.04.2025 18:18:20.26 [Backend]: [LOG] Attempting to run Command ID: ckfs5niws0007v110s447k1ac
[LOG] Targeting Property: "trackPresetPath"
[LOG] With Value: ["z_gen","BASS"]
Logging error in action (01) RunCommandAction: Command 'ckfs5niws0007v110s447k1ac' (ckfs5niws0007v110s447k1ac) not found, from command 'user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc'
15.04.2025 18:18:20.26 [Backend]: [WithFrontmostAppPreservedAction] Saving the current frontmost app 'com.avid.ProTools' before running callback...
15.04.2025 18:18:20.26 [Backend]: [LOG] ERROR during preset recall test: RunCommandAction
15.04.2025 18:18:26.15 [Backend]: [WithFrontmostAppPreservedAction] Re-activating the app 'com.avid.ProTools' after callback...
[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'
NSArray.ArrayFromHandle count = 0
[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'
NSArray.ArrayFromHandle count = 1
[WithFrontmostAppPreservedAction] Re-activation succeeded after 0.01 seconds
<< Command: test track preset [user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc]
[KeyboardInterfaceController] Invalidating PT memlocs due to numpad enter
15.04.2025 18:18:27.00 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
15.04.2025 18:18:35.09 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js
What happens when you run this script?
I'm trying to make a script to recall track presets in Pro Tools. I'm aware I can make a macro, but this little process will ultimately be a part of a larger prep script that does a bunch of other things.
I couldn't figure out how to recall a track preset without making a macro first.
I right clicked > copied the macro, and pasted this information into Gemini 2.5 to create this script.
Gemini seems to think sf.ui.proTools is missing certain commands it's supposed to have. I've already deleted and re-installed the ProTools package.
Do you think this might be the case? If I can recall a track preset via macro successfully, surely I can run one from a script, no?
I'm new to this, so there's a high chance of user error of course.
What do yall think??
Here is the Gemini diagnosis fwiw:
You have gathered all the necessary information to report this effectively:
Your Setup: SoundFlow 5.10.3, Pro Tools 2024.10.2, Pro Tools Package v1.1.9, your macOS version.
The Core Problem: Standard commands and functions from the official Pro Tools package are not available to scripts.
Specific Examples:
Inspection of sf.ui.proTools shows only basic UI elements, missing track commands.
Direct call sf.ui.proTools.trackRecallPreset fails with "Object has no method".
Calling the pre-built "Recall Track Preset on Selected Track" command via sf.soundflow.runCommand using the ID ckfs5niws0007v110s447k1ac (derived from its _commandKey) fails with "Command ... not found".
Confirmation: Mention that you have reinstalled the Pro Tools package and that you can manually recall the track presets within Pro Tools itself.
Only the SoundFlow team can likely diagnose why the package isn't loading correctly for your specific configuration. It might be a bug, a conflict, or an installation quirk they need to address.
I'm sorry we hit this roadblock, but we've clearly identified it's an environment issue rather than a scripting logic one at this point.
How were you running this script?
I clicked the "Run Script" or "Run Macro" button in SoundFlow
How important is this issue to you?
5
Details
{ "inputExpected": "Recall a track preset in Pro Tools", "inputIsError": true, "inputError": "15.04.2025 18:18:07.70 [EditorWindow:Renderer]: Active Focus Container: commandsPage/commands Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:08.08 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:08.09 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:08.09 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:08.10 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:08.14 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:09.73 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:09.74 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:09.81 [EditorWindow:Renderer]: Active Focus Container: commandsPage/folders Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:09.84 [EditorWindow:Renderer]: Active Focus Container: namePopup Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:11.29 [EditorWindow:Renderer]: Active Focus Container: commandsPage/commands Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:13.83 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:14.97 [EditorWindow:Renderer]: User Data Store data changed Line 56036 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:14.97 [EditorWindow:Renderer]: Updating User Settings. officialPackages= 7 Line 56119 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:14.99 [EditorWindow:Renderer]: Invalid version: {\"min\":\"SoundFlow 5.8.1\"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:14.99 [EditorWindow:Renderer]: Package Sparrow MIDI Faders from Lee K Martin has set SF version to >= 'SoundFlow 5.8.1' [EditorWindow:Renderer]: Package DADman from Keeley has set SF version to >= '5.04' [EditorWindow:Renderer]: Invalid version: {\"min\":\"5.04\"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:15.09 [Backend]: [SF_FIREBASE_WS]: Received 3103 bytes. Total received: 128784\n\n15.04.2025 18:18:15.09 [Backend]: [RunCommandNode::Deserialize] Macro has a RunCommandNode with commandId 'user:cli50xtc200015210vyksy31z:clik0aumb0018y510wqhabfnv#clik0opvm002cy510n07kmaa0', which could not be resolved\n\n15.04.2025 18:18:15.09 [Backend]: [ConfigurationController] LoadConfigurationAsync user 'zidcniFSLhRbSKJI4WnurSPSZfJ3' effective changeType 'ScriptSource' reason 'SetJson' changedPath '/customCommandPackages/cm9htimyr0000cj102py228sv/commands/cm9j8kyg8000eda10a60hlgsc/source' hasCloudPro: True: \n[ConfigurationController] Could not patch script source, falling back to re-reading configuration from scratch\nEffective Active User Profile: default\n\n15.04.2025 18:18:15.09 [Backend]: [SF_FIREBASE_WS]: Received 44 bytes. Total received: 128828\n\n15.04.2025 18:18:15.09 [EditorWindow:Renderer]: User Data Store data changed Line 56036 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:15.09 [EditorWindow:Renderer]: Updating User Settings. officialPackages= 7 Line 56119 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Invalid version: {\"min\":\"SoundFlow 5.8.1\"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Invalid version: {\"min\":\"5.04\"} Line 550592 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:15.10 [EditorWindow:Renderer]: Package Sparrow MIDI Faders from Lee K Martin has set SF version to >= 'SoundFlow 5.8.1' [EditorWindow:Renderer]: Package DADman from Keeley has set SF version to >= '5.04' [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:20.09 [EditorWindow:Renderer]: Calling backendwebclient sendasync: /commands/run [object Object] Line 56597 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:20.09 [Backend]: Received run command: user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc\n\n15.04.2025 18:18:20.09 [Backend]: >> Command: test track preset [user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc]\n[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'\n\n15.04.2025 18:18:20.09 [Backend]: NSArray.ArrayFromHandle count = 1\n\n15.04.2025 18:18:20.09 [Backend]: [ServerController] Running command from sfgui: 'test track preset' (user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc)\n\n15.04.2025 18:18:20.20 [Backend]: Mouse current pos is: (921.97265625, 337.375)\nClicking with mouse here: (10, 60)\n\n15.04.2025 18:18:20.21 [Backend]: Moving mouse back to: (921.97265625, 337.375)\n\n15.04.2025 18:18:20.21 [Backend]: Position is now: (921.97265625, 337.375)\n\n15.04.2025 18:18:20.23 [Backend]: ProTools version: 24.10.2.205 class: PT2024_10\nProTools processID: 1068\n\n15.04.2025 18:18:20.23 [Backend]: Pro Tools language: English\n\n15.04.2025 18:18:20.26 [Backend]: [LOG] Target track selected: Hits_FX Stinger\n\n15.04.2025 18:18:20.26 [Backend]: [LOG] Attempting to run Command ID: ckfs5niws0007v110s447k1ac\n[LOG] Targeting Property: \"trackPresetPath\"\n[LOG] With Value: [\"z_gen\",\"BASS\"]\nLogging error in action (01) RunCommandAction: Command 'ckfs5niws0007v110s447k1ac' (ckfs5niws0007v110s447k1ac) not found, from command 'user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc'\n\n15.04.2025 18:18:20.26 [Backend]: [WithFrontmostAppPreservedAction] Saving the current frontmost app 'com.avid.ProTools' before running callback...\n\n15.04.2025 18:18:20.26 [Backend]: [LOG] ERROR during preset recall test: RunCommandAction\n\n15.04.2025 18:18:26.15 [Backend]: [WithFrontmostAppPreservedAction] Re-activating the app 'com.avid.ProTools' after callback...\n[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'\nNSArray.ArrayFromHandle count = 0\n[NSRunningApplication (static)] Checking for running apps with bundle 'com.avid.ProTools'\nNSArray.ArrayFromHandle count = 1\n[WithFrontmostAppPreservedAction] Re-activation succeeded after 0.01 seconds\n<< Command: test track preset [user:cm9htimyr0000cj102py228sv:cm9j8kyg8000eda10a60hlgsc]\n[KeyboardInterfaceController] Invalidating PT memlocs due to numpad enter\n\n15.04.2025 18:18:27.00 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n15.04.2025 18:18:35.09 [EditorWindow:Renderer]: Active Focus Container: code Line 33963 file:///Applications/SoundFlow.app/Contents/Helpers/SoundFlow.app/Contents/Resources/app.asar/dist/editor.js\n", "inputWhatHappens": "I'm trying to make a script to recall track presets in Pro Tools. I'm aware I can make a macro, but this little process will ultimately be a part of a larger prep script that does a bunch of other things.\n\nI couldn't figure out how to recall a track preset without making a macro first. \n\nI right clicked > copied the macro, and pasted this information into Gemini 2.5 to create this script.\n\nGemini seems to think sf.ui.proTools is missing certain commands it's supposed to have. I've already deleted and re-installed the ProTools package.\n\nDo you think this might be the case? If I can recall a track preset via macro successfully, surely I can run one from a script, no?\n\nI'm new to this, so there's a high chance of user error of course.\n\nWhat do yall think??\n\nHere is the Gemini diagnosis fwiw:\nYou have gathered all the necessary information to report this effectively:\n\nYour Setup: SoundFlow 5.10.3, Pro Tools 2024.10.2, Pro Tools Package v1.1.9, your macOS version.\n\nThe Core Problem: Standard commands and functions from the official Pro Tools package are not available to scripts.\n\nSpecific Examples:\nInspection of sf.ui.proTools shows only basic UI elements, missing track commands.\n\nDirect call sf.ui.proTools.trackRecallPreset fails with \"Object has no method\".\nCalling the pre-built \"Recall Track Preset on Selected Track\" command via sf.soundflow.runCommand using the ID ckfs5niws0007v110s447k1ac (derived from its _commandKey) fails with \"Command ... not found\".\n\nConfirmation: Mention that you have reinstalled the Pro Tools package and that you can manually recall the track presets within Pro Tools itself.\n\nOnly the SoundFlow team can likely diagnose why the package isn't loading correctly for your specific configuration. It might be a bug, a conflict, or an installation quirk they need to address.\n\nI'm sorry we hit this roadblock, but we've clearly identified it's an environment issue rather than a scripting logic one at this point.", "inputHowRun": { "key": "-MpfwYA4I6GGlXgvp5j1", "title": "I clicked the \"Run Script\" or \"Run Macro\" button in SoundFlow" }, "inputImportance": 5, "inputTitle": "Trouble recalling track presets via script" }
Source
// Simple Test Script for Recalling a Specific Track Preset via Command
// (Updated for correct props format based on new JSON data)
try {
// 1. Ensure Pro Tools is active
sf.ui.proTools.appActivateMainWindow();
sf.ui.proTools.invalidate();
// 2. Get the currently selected track (MAKE SURE ONE TRACK IS SELECTED IN PRO TOOLS FIRST)
const selectedTracks = sf.ui.proTools.selectedTrackNames;
if (selectedTracks.length !== 1) {
throw "SCRIPT ABORTED: Please select exactly ONE track in Pro Tools to apply the preset to.";
}
const targetTrackName = selectedTracks[0];
log(`Target track selected: ${targetTrackName}`);
// 3. --- Define Preset Details for Testing ---
// Should match the details in the latest JSON data provided
const presetCategoryToTest = "z_gen"; // Category folder name (From JSON)
const presetNameToTest = "BASS"; // Preset name WITHOUT .ptxp (From JSON)
// !!! Change this if you want to test a different preset !!!
// -----------------------------------------
// 4. Define Command Details (Derived from your JSON data)
const recallCommandId = 'ckfs5niws0007v110s447k1ac'; // From _commandKey
const presetPathPropertyName = 'trackPresetPath'; // From data.props key
// 5. *** Construct the Property Value Array based on CORRECT JSON Format ***
// Format: [CategoryName, PresetNameWithoutExtension]
const presetValueArray = [presetCategoryToTest, presetNameToTest];
// **********************************************************************
log(`Attempting to run Command ID: ${recallCommandId}`);
log(`Targeting Property: "${presetPathPropertyName}"`);
log(`With Value: ${JSON.stringify(presetValueArray)}`); // Log the new array format
// 6. Execute the command
sf.soundflow.runCommand({
commandId: recallCommandId,
props: {
// Use the property name 'trackPresetPath'
// Pass the value as the corrected array [Category, Name]
[presetPathPropertyName]: presetValueArray
}
});
// 7. If it reaches here, the command execution didn't throw an immediate error
log("sf.soundflow.runCommand executed without throwing a JavaScript error.");
alert(`Preset recall command sent for preset "${presetNameToTest}" (Category: "${presetCategoryToTest}") on track "${targetTrackName}".\n\nPlease check the track in Pro Tools to see if it was actually applied.`);
} catch (e) {
// Log and alert if any error occurs during the script execution
log(`ERROR during preset recall test: ${e.message}`);
// log(`Full Error: ${JSON.stringify(e)}`); // Uncomment for more detailed error object
alert(`SCRIPT ERROR: ${e.message}\n\nCheck SoundFlow logs for details.`);
}
Links
User UID: zidcniFSLhRbSKJI4WnurSPSZfJ3
Feedback Key: sffeedback:zidcniFSLhRbSKJI4WnurSPSZfJ3:-ONwCVJiAQZd9DGu0rSO
Feedback ZIP: aHRcpJ06S99/wshDfwsMnTsv7FPHtDEfGl/Uulizm7jo5wc9yV9yBZ4a1KlmfEBgcjzLhIEGMON/rnk8u7o39X5WwTE1tP9Vw+tHky7suvFfourztk5KfW8WaP6UkKAjU7QlT24CXslEz+iyVJskVyKtYbMc5TdpgHcmNmcxiSSVz6HNFc+tYLDpdoNsm695JtwQ4XtmvU/J0Ve9n89qk73XIKqiUsUpQ7svjySZ8o6u8fwYDtohhS8z/S58R1PbVf4oyhimgwEvYDowna8UGeXtDU9jxs6F1FEHPbHCSeXJicMrUMnN38nembrReF6hdPrrLBZZAqvNSVaMlwhxXA==