Skip to main content

I ran into the following situation.

We have a topic branch from the MAIN (lest assume it is called TOPIC_1) and from TOPIC_1 we made a new branch TOPIC_1_1.

I created 2 merge sessions:

  1. TOPIC_1_1 back to TOPIC_1
  2. TOPIC_1 back to MAIN

I foolishly assumed that when I would start the merge task it would merge down from the first. But it executes the currently selected merge session.

So I ended up with TOPIC_1 being merged back to MAIN but without the contents of TOPIC_1_1 as that is merged to the inactive (I didn't notice the real issue until I merged both sessions 😉 )

I ended up fixing it by re-activating both branches and create new merge sessions and running those in the correct order…

I think it would be nice if there are some checks that would warn if you try to merge a brange which still has open sub branches!?
 

Hi Alban,

Starting a merge session and executing a merge session are two separate processes that should be started and finished together.

By starting merge sessions for both TOPIC_1_1 to TOPIC_1 and TOPIC_1 to MAIN at the same time, will cause the TOPIC_1 to MAIN merge session to miss all delta actions (let's say affected objects) that could occur after executing the TOPIC_1_1 back to TOPIC_1 merge session.

It is recommended to first start and execute merge session TOPIC_1_1 to TOPIC_1. You can verify the result by running tests such as manual tests, unit tests and smoke tests in TOPIC_1. We typically do a Creation run and upgrade our development environment before starting a next merge session. 

Thereafter start and execute the merge session for TOPIC_1 to MAIN. This will ensure that any changed that have occurred after the execution of the first merge session, will be taken into consideration for the second merge session.

 


And how to fix it when it went wrong by accident?
 


You can consider reverting to the moment in time just before the merge. Do inspect the changes that will be done as reverting cannot be undone once finished. More info here: https://docs.thinkwisesoftware.com/docs/sf/overview#revert-a-branch

 


Hi Alban,

Is the problem resolved?

One thing to note is that when merging from the origin to the branch, the origin model version is also updated which is needed to determine differences between origin and branch. In case you revert to a point-in-time before this merge, the origin model version is now incorrect. We have been made aware of this. To resolve this, update this field to match the last "Updated branch” model version or if not there the "Created branch” model version.