Nested Live Script Execution Issue in MATLAB 2023b

46 次查看(过去 30 天)
I recently encountered an issue while running MATLAB 2023b where I'm unable to execute a Live Script (.mlx) from within another Live Script in a batch processing context. Specifically, my scenario involves a batch processor script (also a .mlx file) designed to run another Live Script multiple times for different sets of data.
The error message I receive is "Nested Live Editor execution is not supported." This behavior seems to be new in the 2023b version, as the same code worked in earlier versions.
Could you help me understand why this limitation has been introduced in MATLAB 2023b? Additionally, I would appreciate any recommendations or best practices for handling such scenarios where a batch process needs to execute a Live Script multiple times. Are there alternative approaches or workarounds that align with MATLAB's intended usage patterns?
Thank you for your assistance!

回答(1 个)

Pavan Sahith
Pavan Sahith 2024-8-6,11:23
Hello,
I also encountered a similar issue when using the 'export() function in nested live scripts to export a live script in MATLAB R2024a. Interestingly, the same code worked perfectly in version R2023a.
While I don't have a detailed explanation or reason for this behavior, I found a workaround that resolved the issue for me.
Instead of running 'export()' within another live script, I used a regular .m file. This approach helped me avoid the nested live script execution issue.
So,in your case, if it's possible you might consider converting the Live Script you want to run multiple times into a regular .m file. You can then call this .m file from your batch processor script. This should help you bypass the "Nested Live Editor execution is not supported" error.
Hope it Helps !

类别

Help CenterFile Exchange 中查找有关 Environment and Settings 的更多信息

产品


版本

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by