Closed Bug 1499305 Opened 6 years ago Closed 6 years ago

Can't set up 'hg phabread' - abort: Can't find conduit token associated to https://phabricator.services.mozilla.com/

Categories

(Conduit :: Phabricator, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: jorgk-bmo, Unassigned)

Details

I'm on Mercurial 4.7.2. I set up the HG integration according to https://www.mercurial-scm.org/wiki/Phabricator#Setting_up_hg This is what I have in my hgrc file: [phases] # Use draft commits publish = False [extensions] # older than 4.8 phabricator = ../../.mozbuild/phabricator.py [experimental] # obsstore needs to be used for tracking which commit belongs to which Differential Revision and their versions evolution = createmarkers, allowunstable [phabricator] url=https://phabricator.services.mozilla.com/ callsign=HG # 4.7 and later [auth] hg.schemes = https hg.prefix = https://phabricator.services.mozilla.com/conduit/login/ hg.phabtoken = ??? First problem: It's unclear how to specify absolute path on Windows: This works phabricator = ../../.mozbuild/phabricator.py but this doesn't phabricator = /c/mozilla-source/.mozbuild/phabricator.py However, the shell can see the file. $ ls /c/mozilla-source/.mozbuild/phabricator.py /c/mozilla-source/.mozbuild/phabricator.py The second problem is more severe: No idea how to set up the token. The instructions say: hg.phabtoken = cli-SOMENOISEHERE However, all tokens I have start with api, so api-SOMENOISEHERE. I tried using the api-SOMENOISEHERE, or with a cli- prepended, or without the api-, nothing works: abort: Can't find conduit token associated to https://phabricator.services.mozilla.com/ Note: I had that set up and working on another machine in my second office, but sadly forgot to bring the file with me when switching offices. A little sad that it appears impossible just to do it again. Or maybe the original setup also stopped working now.
Flags: needinfo?(mozilla)
that extension is one that the mercurial project supports, not the conduit team. we recommend instead setting up arcanist and moz-phab - see https://moz-conduit.readthedocs.io/en/latest/phabricator-user.html you may be able to find someone on irc in the #vcs or #hg channel that could help, otherwise try #mercurial on the freenode irc network.
Status: NEW → RESOLVED
Closed: 6 years ago
Flags: needinfo?(mozilla)
Resolution: --- → INVALID
Sorry, but the Windows setup is just too complicated: https://moz-conduit.readthedocs.io/en/latest/arcanist-windows.html Not sure why you cancelled the NI if you actually didn't provide any help.
Flags: needinfo?(mozilla)
Maybe try with native windows paths: c:/mozilla-source/.mozbuild/phabriactor.py > # 4.7 and later Do you have a copy of phabricator.py from 4.7 or later? You can find the token under settings > Conduit API tokens.
Flags: needinfo?(mozilla)
(In reply to Jorg K (GMT+2) from comment #2) > Sorry, but the Windows setup is just too complicated: > https://moz-conduit.readthedocs.io/en/latest/arcanist-windows.html > > Not sure why you cancelled the NI if you actually didn't provide any help. this isn't the right place to get help with mercurial's extension. the help i provided was to point to at an alternative, and at better locations to get said help.
Found the problem, incorrect config, needs to be: [auth] hg.schemes = https hg.prefix = phabricator.services.mozilla.com hg.phabtoken = api-SOMENOISEHERE
(In reply to Tom Prince [:tomprince] from comment #3) > Maybe try with native windows paths: > c:/mozilla-source/.mozbuild/phabriactor.py That didn't work, but otherwise it's working again now. Too bad I didn't carry the hgrc file with me :-(
For the record, this works: phabricator = c:\mozilla-source\.mozbuild\phabricator.py
You need to log in before you can comment on or make changes to this bug.