11-19-2020 02:55 AM
Hi, guys!
I have an issue.
I tested git vcs on my labview project and found out a curious behavior on class vis (which are methods). Simple labview vi's behaviour is as-expected.
I use last stable git release and LabVIEW 15.0.1f13(32bit).
1. I have traingle class and its getter method getArea (see fig. 1).
2. A bd of the vi is displayed on fig. 2.
3. Then I modify my bd - changing multiplier on calc expresion (don't ask why) fig. 3.
4. I decide this changes has to be on staging area fig. 4.
5. I also can see my tortoise git client see this file as modified fig. 5.
6. Time goes by and I finally realise it was a bad idea to do so. So - first - I unstage this file (fig. 6) and - second - checkout to my last commit state (fig. 7)
7. I expect to see my file as in fig. 1, but when I open it in project window it has fig.3 state.
The issue is binary vi file was REALY restored to its unchanged condition (fig. 8). But LabVIEW some how don't see it.
What am I doing wrong or what concept slips away from me?
11-19-2020 04:43 AM
Hi,
The issue here is not related to git ( or other VCS).
LV doesn't react automatically to a change made on a vi file outside of LV.
Here you need to close/open your project or use the revert command (menu File>>Revert) on getArea.vi.
11-19-2020 06:35 AM - edited 11-19-2020 07:06 AM
Thank you for your reply!
1. "Revert" option in File menu greyed and disabled.
2. Project restart DOES affect on the file.
3. Computer restart affects, but I'm not sure that this is the right way for workflow.
4. I don't observe such behaviour on vi that is not part of class. Any thoughts?
upd: option to restart project is vital, but there must be easier solution.
11-19-2020 07:39 AM
To have access to the revert item, you need to have the vi marked as modified (with the *). Just move a wire and make the revert, it'll work.
Restarting the computer is definitely not necessary nor recommended
Being part of a class should not change the behavior. The one you described seems to be the right one, but to be fair all my vis are in a class or lib. I can be wrong on that part.