Check if Models provided by the Version Control Systems are Readable
There are a couple of reasons why LemonTree might be reporting an error when launched as a Diff/Merge Tool - even though you've set everything up correctly according to one of our guides on VCS Integration found here: VCS Integration.
One of the possible issues is that the files provided by the Version Control System are not in a correct format or otherwise unreadable by LemonTree, which will lead to an error message appearing during the diff/merge. This guide will show you how to locate the files and how you can determine if they are valid.
1. Locating the models provided by the Version Control System
There's currently no easy, universal way to locate the files passed to LemonTree on your harddisk. There's two reasons for that:
- The files LemonTree is trying to diff/merge will be written to a temporary folder on your harddisk, and have a different name every time
- The location of the temp folder is dependent on which Git tool you're actually using
If you know how to find them, that's great! You can skip directly to Step 2 in that case.
Otherwise, we'll have to do some digging in the log-files.
Opening the Log-File
If you've been shown the above message (and haven't closed it yet), clicking on the hyperlink at the bottom will automatically open the main LemonTree Log-File.
Otherwise, navigate to this folder on your harddrive:
and open the file "LemonTree.log" with a Text Editor.
Locating the correct log entry
In the Log-File, we are looking for an entry that is written every time LemonTree is started. It looks something like this:
10632|2020-02-26 10:31:49,047|INFO|SystemLogger|LemonTree.Desktop.Program.Main|1:||Arguments: "C:\Program Files\LieberLieber\LemonTree\LemonTree. exe" --merge=auto --wait --out=C:\@Work\Git\Sandbox\Data\Variant\ATM.eap --mine=C:\Users\UBRUNF~1\AppData\Local\Temp\smartgit-901982657886863245tmp\conflict-solver\ATM-ours--1757252454736697744.eap --theirs=C:\Users\UBRUNF~1\AppData\Local\Temp\smartgit-901982657886863245tmp\conflict-solver\ATM-theirs--4844152928677077443.eap --base=C:\Users\UBRUNF~1\AppData\Local\Temp\smartgit-901982657886863245tmp\conflict-solver\ATM-base--124098459906475191.eap|
Usually, your best bet is to search for the last occurence of the text "Arguments: " (without the quotes).
Making sense of the log entry
The log entry contains the entire call of LemonTree. As such it also contains all the parameters passed on, which are what we're interested in. Specifically, there are three parameters that look like this:
- --mine=(Some Path)
- --theirs=(Some Path)
- --base=(Some Path)
The (Some Path) components are paths on your local harddrive to the three files passed on to LemonTree. We are omitting the Parameter "--out=(Some Path)" on purpose - that's the path where LemonTree will write the merge result, and there's no file there (yet).
For now, copy these 3 paths somewhere you'll have them handy for the next step.
2. Testing if the models are readable
Now that we've determined which files LemonTree is trying to process, we can check if the files are actually readable.
The easiest way to do so is to open the model located at each path determined during Step 1 with your installed Enterprise Architect version.
- If the model loads incorrectly or not all, the models supplied by the Version Control System are likely faulty.
One of the known cases where this can occur is if Git LFS is set up incorrectly. For more details, please see this page: Verify Git LFS Setup
- If the model loads up correctly and Enterprise Architect doesn't report any errors, the data is delivered correctly from the Version Control System.
In this case, the problem more than likely lies within LemonTree itself, and we would appreciate it if you would report an error if you haven't done so already: Report an Issue.