Page MenuHomePhabricator

Getting error "Undefined index: Repository UUID" while doing arc diff --preview command, although diff is generated ok
Closed, WontfixPublic

Description

I am facing with this error when making arc diff --preview command :

ERROR 8: Undefined index: Repository UUID at [...]
[...]
SKIP STAGING Unable to determine repository for this change.

Possible similar issues:
It seems is similar to this task: T10460, but I cannot make the error disappear.

Reproduction Steps:
I want to avoid the file .arcconfig, so I am setting the properties directly this way:

arc set-config default <URI>

cat ~/.arcrc

{
  "config": {
    "default": "<URI>"
  },
  "hosts": {
    "http:<URI>/api": {
      "token": "<token>"
    }
  }
}

It seems I do not include the callsign of a repository. I tried to set properties like these ones without success:

arc set-config repository.callsign <REPO CALLSIGN PREVIOUSLY DEFINED>

or

arc set-config callsign <REPO CALLSIGN PREVIOUSLY DEFINED>

The question if there is a way to do this and have this configuration in ~/.arcrc file

Versions
arcanist 20ad47f2733135603d57b57be3e13422397e8071 (Fri, May 5)
phutil d02cc05931b02c684d4c729510090591ca45f951 (Sat, Apr 29)

Thanks in advance.
Juan

Event Timeline

cxzzero updated the task description. (Show Details)

You can user arc set-config --local to set a configuration value in a file that is in the repository but is not committed.

As to Repository UUID, that probably shouldn't throw an exception (Most repositories are not expected to have a UUID).

Thanks for your reply.

When you say arc set-config --local , when does the configuration for this get written to?

I tried to do something like this: arc set-config --local repository.callsign <CALLSIGN>, but I cannot see where is the information stored. Is it an environmental variable involved?

It saves it to a directory called arc in your repository meta-directory. If you're using git, it would be in .git/arc/.

Excellent! Thanks @avivey.
This ticket could be closed.

avivey claimed this task.