JKI-State-Machine-Objects
JKI-State-Machine-Objects copied to clipboard
SMO Editor deleted some of my code
The JKI SMO Editor removes the Typedefs from my SMO when I add a public method.
- Create a blank Project
- Use the SMO Editor to add a BasicByRefWithEvents SMO
- Confirm you can run the TestLauncher VI ✅
- Use the SMO Editor to add a public method
- Observe an error dialog appears ❌
- Observe the Typedefs folder is now empty ❌
Usually, when a tool's operations on user data can fail, they can be rolled back by the tool. It would be helpful if these workflows were made transactional: apply-or-noop.
Add a public method

Error dialog

Empty Typedefs folder

Error text
Error 8 occurred at Invoke Node in ProjectItem.JKI SMO.lvclass:New PublicEvents--DataCluster.vi->ProjectItem.JKI SMO.lvclass:Add New Event.vi:690001->ProjectItem.JKI SMO.lvclass:Add ProtectedEvents--DataCluster.vi->JKI SMO Editor.lvclass:AddEvent.vi
Possible reason(s):
LabVIEW: (Hex 0x8) File permission error. You do not have the correct permissions for the file.
Method Name: Save:Instrument
Before / after projects
Software
- macOS 10.13.4 (17E202) "High Sierra"
- LabVIEW 2018 64-bit
- JKI SMO Editor 2.0.1.4
JKI SMO Editor v2.0.1.4 by JKI
Released On: Wed, 27 Apr 2016 08:59:07 -0700
Author: JKI
Copyright: Copyright (c) 2016, JKI
Compatible LabVIEW Versions: >= 2013.
Compatible OS Versions: ALL.
Repository Name: JKI Package Network
Release Notes:
- Changed Public Method to use Private Events to message Process.
- Event can now be empty (boolean placeholder)
- Event that contains only one control will not wrap into a cluster
This Package depends on these other packages:
jki_lib_state_machine >= 2.0.0
OpenG Array Library >= 4.1.1.14
OpenG Error Library >= 4.2.0.23
OpenG File Library >= 4.0.1.22
OpenG LabVIEW Data Library >= 4.2.0.21
OpenG String Library >= 4.1.0.12
OpenG Variant Configuration File Library >= 4.0.0.5
JKI SMO Templates >= 1.0.0.5
JKI State Machine Objects (SMO) >= 1.0.0.11
I have to congratulate you on the detailed bug report.
You've pointed to a very important missing feature in the tool: transaction begin and undo. At this time, they are non-existent.
The SMO Editor is not part of this open-source project and is currently not published. I know that JKI's intent was to open source it as well so that the community can propose improvements. The code for the editor is not password protected, so it can de inspected and debugged. (If interested, the main VI is located at <LabVIEW folder>\project\SMO Edition.vi)
The type of errors you are seeing looks like they are from disk permission errors. I am not well versed in LV for MacOS, so I'll let others chip in with comments. (I've never seen the sequence of errors you describe in the Windows version... although similar errors would probably produce similar results because of the absence of transaction wrappers.)
Regarding the editor: Do you personally use it Francois? A find it a little cumbersome to use even if I like the SMO framework a lot.
I have to admit that I don't use the SMO Editor in its current state. I personally always start from a blank object and inherit from SMO Base, then grow it manually. I spend way more time in the object architecture than in creating methods, so even though it is fastidious to repeat the same patterns by hand, I found that it still worked for me.
I heard that many people use openGDS to script their methods and accessors for SMO (and other frameworks).