Robomerge opened -x

Hello guys,

I want to ask a question related to Robomerge.

We are running robomerge in a non-distributed p4 setup - There is just one p4 server + replica. No edge servers.

While the merging is working most of the time without issues, robomerge sometimes tries to run “opened -x” command and throws an exception.

{“data”:“This command is only supported in a distributed configuration.\n”,“generic”:1,“severity”:3}

This stops the robomerge server and it has to be restarted. (Full log attached)

Strangely, it skips the whole “opened -x” afterwards and proceeds without errors:

robomerge-1 | 2025/10/08 15:00:07.553 [ROBOMERGE:dl=>sim-pres-split]: Merging CL 40434 via ROBOMERGE dl -> sim-pres-split (normal)

robomerge-1 | 2025/10/08 15:00:07.554 [ROBOMERGE:dl=>sim-pres-split]: Integrating CL 40434 to sim-pres-split

Is there any workaround for this issue?

I think robomerge falsely assumes there is an edge-server to run the command against which is not true.

From perforce.ts:

const serversOutput = await PerforceContext.execAndParse(logger, null, [“servers”]);

perforceMultiServerEnvironment = serversOutput.length > 1

opened(roboWorkspace: RoboWorkspace \| null, arg: number \| string, exclusive?: boolean) {

    const workspace \= roboWorkspace \&\& coercePerforceWorkspace(roboWorkspace);

    const args \= \['opened']

    if (typeof arg \=\=\= 'number') {

        // see what files are open in the given changelist

        args.push('\-c', arg.toString())

    }

    else {

        // see which workspace has a file checked out/added

        args.push(exclusive \&\& perforceMultiServerEnvironment ? '\-x' : '\-a', arg)

    }

    return this.execAndParse(workspace, args) as Promise\<OpenedFileRecord\[]\>

}

Where p4 servers command in our env returns the following:

perforce-p66_forwarding-replica1 server 2kgadcp4r13:1666 forwarding-replica ‘’

perforce-p66_master server 2kgla1p4s6.2kgames.t2.corp:1666 standard ‘’

Thanks,

Michal

Steps to Reproduce

Hi Michal, apologies for the trouble. First off just a bit of boilerplate which is to clarify that robomerge is not officially supported and while we do share the code, it is developed and tested solely for our own internal purposes and external facing documentation, testing, and general support is out of scope of what we can provide at the time being.

As you may therefore guess, we have no single server testing environment that is in regular use. If I recall that multi server code was put together when doing some testing against our Demo test server which is just a single server set up.

I’m really not sure why it wouldn’t occur on a second run, presumably whatever is calling opened avoids being called the second time around, though that is concerning in its own way.

I think that a more nuanced determination of whether it is a multiServerEnvironment will solve your issue:

multiServerEnvironment: serversOutput.some(server => server['Type'] == 'edge-server'),If you want to give that a try and let me know if it works I can commit it to the repository.

Hello Marc,

Yeah, I’m aware the tool is not officially supported and sometimes requires a bit of reverse engineering.

I’ll try adjust the source code and deploy the new version to test it.

It might take a while until we come again across an opened command again (happens approx. once a month).

Thank you for your help.

Best Regards,

Michal