DSS + Source Management (e.g. Github)

Use this forum to post Vensim related questions.
Post Reply
RobbieOrvis
Member
Posts: 43
Joined: Wed Dec 13, 2017 5:16 pm
Vensim version: DSS

DSS + Source Management (e.g. Github)

Post by RobbieOrvis »

Hello,

Moving a prior thread to its own thread here: has there been progress made on using DSS with source management tools, like Github. Previously, when attempting to do merges and other actions, the coordinate system in Vensim would get messed up and cause the model to visually fail. Travis Franck suggested that improvements were made that addressed this, but we still appear unable to successfully manage .mdl files and conduct merges.
Travis
Senior Member
Posts: 141
Joined: Tue Jul 15, 2008 8:42 pm

Re: DSS + Source Management (e.g. Github)

Post by Travis »

@Robbie what Vensim version are you using? I think source control works best on v9.2 or newer. [edited to v9, no v8]
Last edited by Travis on Mon Jan 09, 2023 8:22 pm, edited 1 time in total.
tomfid
Administrator
Posts: 3811
Joined: Wed May 24, 2006 4:54 am

Re: DSS + Source Management (e.g. Github)

Post by tomfid »

Are you using the new file formats in Model>Settings?
2023-01-09_12-57-56.png
2023-01-09_12-57-56.png (29.85 KiB) Viewed 718 times
RobbieOrvis
Member
Posts: 43
Joined: Wed Dec 13, 2017 5:16 pm
Vensim version: DSS

Re: DSS + Source Management (e.g. Github)

Post by RobbieOrvis »

Aha! I have been using the old GUI, which doesn't have these options when I go to Model>Settings. I am gathering might be the issue here since these options aren't available.

I can test more tomorrow using the new GUI and settings above.
RobbieOrvis
Member
Posts: 43
Joined: Wed Dec 13, 2017 5:16 pm
Vensim version: DSS

Re: DSS + Source Management (e.g. Github)

Post by RobbieOrvis »

For what it's worth after some very brief testing, this is still causing merge conflicts when we try to merge separately edited model versions together. I'm not sure if it is a Git configuration setting or something else. The general issue is that when the same line number is edited in two .mdl files and you try to merge, it throws a conflict. It doesn't appear to recognize each variable as hunk and therefore allow for code merging.

For example, I created a couple of new branches in our repository and added a variable name Test Variable 1 in one and Test Variable 2 in the other. If I try to merge these together or try to merge both back into the parent branch, I get merge conflicts for where the new variables are entered into the code in the .mdl file.
Administrator
Super Administrator
Posts: 4590
Joined: Wed Mar 05, 2003 3:10 am

Re: DSS + Source Management (e.g. Github)

Post by Administrator »

If you can send an example, I'd be happy to take a look.
Advice to posters seeking help (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391

Units are important!
http://www.bbc.co.uk/news/magazine-27509559
adelibas
Newbie
Posts: 1
Joined: Thu Jan 12, 2023 7:57 pm
Vensim version: DSS

Re: DSS + Source Management (e.g. Github)

Post by adelibas »

RobbieOrvis wrote: Tue Jan 10, 2023 11:02 pm For what it's worth after some very brief testing, this is still causing merge conflicts when we try to merge separately edited model versions together. I'm not sure if it is a Git configuration setting or something else. The general issue is that when the same line number is edited in two .mdl files and you try to merge, it throws a conflict. It doesn't appear to recognize each variable as hunk and therefore allow for code merging.

For example, I created a couple of new branches in our repository and added a variable name Test Variable 1 in one and Test Variable 2 in the other. If I try to merge these together or try to merge both back into the parent branch, I get merge conflicts for where the new variables are entered into the code in the .mdl file.
Robbie, I see that you are trying to modify the same line of the same file in two separate branches. When you modify the same line of the same file in parallel branches, that creates a conflict by definition in Github (see https://docs.github.com/en/pull-request ... -conflicts).

Having said that I understand where you are coming from: I used different merge tools years ago that could figure out (looking at the common ancestor) that the edits to the same line in two parallel version are actually new lines so it would automatically merge them to include both lines.
Post Reply