LocalParticipantReference, party_migration, and Canton Console

I have an up-and-running participant. I’d like to call repair.party_migration.step1_hold_and_store_acs(…). The second parameter to that function needs to be a LocalParticipantReference. However, when I use Remote Administration, the reference to the participant will be a RemoteParticipantReference. I get a type mismatch error:

@ repair.party_migration.step1_hold_and_store_acs(alice, p1, p2.id, "/bin/canton/demo/alice.acs.gz")

cmd3.sc:1: type mismatch;
 found   : com.digitalasset.canton.console.RemoteParticipantReference
 required: com.digitalasset.canton.console.LocalParticipantReference
val res3 = repair.party_migration.step1_hold_and_store_acs(alice, p1, p2.id, "/bin/canton/demo/alice.acs.gz")
                                                                  ^
Compilation Failed

How do I call repair.party_migration.step1_hold_and_store_acs(…) for an up-and-running participant?


Here is everything you need to reproduce what I am seeing:

docker-compose.yaml
services:

  console:
    image: canton-enterprise:2.6.4
    volumes:
      - $PWD:/canton/demo:ro
    entrypoint: bin/canton
    command: --config /canton/demo/remote.conf

  node:
    image: canton-enterprise:2.6.4
    volumes:
      - $PWD:/canton/demo:ro
    entrypoint: bin/canton
    command: daemon --config /canton/demo/node.conf --log-profile container
    expose:
      - 4001 # p1 ledger-api
      - 4002 # p1 admin-api
      - 4003 # p2 ledger-api
      - 4004 # p2 admin-api
      - 4201 # domain public-api
      - 4202 # domain admin-api
node.conf
canton {
  domains {
    mydomain {
      public-api.address = 0.0.0.0
      public-api.port = 4201
      admin-api.address = 0.0.0.0
      admin-api.port = 4202
    }
  }
  participants {
    p1 {
      ledger-api.address = 0.0.0.0
      ledger-api.port = 4001
      admin-api.address = 0.0.0.0
      admin-api.port = 4002
    }
    p2 {
      ledger-api.address = 0.0.0.0
      ledger-api.port = 4003
      admin-api.address = 0.0.0.0
      admin-api.port = 4004
    }
  }
}
remote.conf
canton {
  remote-domains {
    mydomain {
      public-api.address = node
      public-api.port = 4201
      admin-api.address = node
      admin-api.port = 4202
    }
  }
  remote-participants {
    p1 {
      ledger-api.address = node
      ledger-api.port = 4001
      admin-api.address = node
      admin-api.port = 4002
    }
    p2 {
      ledger-api.address = node
      ledger-api.port = 4003
      admin-api.address = node
      admin-api.port = 4004
    }
  }
}
sample commands
docker compose up --detach node

docker compose run console

@ p1.domains.connect_local(mydomain)

@ p2.domains.connect_local(mydomain)

@ val alice = p1.parties.enable("alice")

@ repair.party_migration.step1_hold_and_store_acs(alice, p1, p2.id, "/bin/canton/demo/alice.acs.gz")

Hi!
Thanks for reporting. In the past, we did not have the tooling to export/import ACS for remote nodes so this created the limitation that you mention.
I’ll do a PR to remove this limitation and it will be available in Canton 2.7.2
Raf