Isn't this more or less the same issue as arc set-config needs to update either local or global configs?
- Queries
- All Stories
- Search
- Advanced Search
- Transactions
- Transaction Logs
Advanced Search
Jul 22 2016
In T11364#186934, @epriestley wrote:Specifically, I'd like to understand what concrete pathway led you to encounter this. A list of hypothetical situations isn't useful in anticipating or recovering from broader problems.
Specifically, I'd like to understand what concrete pathway led you to encounter this. A list of hypothetical situations isn't useful in anticipating or recovering from broader problems.
@epriestley Because it allows the reader of this report to reproduce the underlying issue without cloning anything or clobbering their .arcrc. Here are some less contrived scenarios, which are not mutually exclusive:
- the user makes a typo (project lacking .arcconfig, or trying to use Phabricator for the first time themselves)
- the .arcconfig comes from a time before Let's Encrypt (e.g. if you're in the middle of a git bisect that takes you back some distance)
- the admin is just attempting to migrate people to more secure services and does not expect that services will fail (or at least not fail in such an opaque and confusing manner) in the face of a redirect
This looks closer to a server configuration issue to me and is actually a pretty strange behavior (mostly because i'm not sure how the redirect after it looks like a request is served works). If I go to http://secure.phabricator.com/api/user.whoami in the browser i get the following
{
result: null,
error_code: "ERR-CONDUIT-CORE",
error_info: "You are trying to save some data to Phabricator, but the request your browser made included an incorrect token. Reload the page and try again. You may need to clear your cookies. This was a Web request. This request had no CSRF token."
}as expected or maybe not? However if i run curl http://secure.phabricator.com/api/user.whoami i get
{"result":null,"error_code":"ERR-INVALID-SESSION","error_info":"Session key is not present."}Why are you running arc install-certificate with a manually entered URL?
arc upgrade: Upgrade everything? This feels sort of bad/dangerous, maybe? But maybe fine? We could prompt?
I guess you're right. We've never really questioned the behaviour of these GUI tools. We assumed that because they do this automatically and provide no way to disable it "they'll probably know what they're doing".
Part of the tension here is that any package-related command potentially has two targets: arc itself, or the current working directory (Phabricator, some third-party app you're developing, etc).
(We could detect this case and fail with an error, but the root issue here seems to be that tracking is being set on a remote branch which the local branch really does not track.)
Generally, I'm very hesitant to use "will the push change anything" as a signal, because I think this is unintuitive and will create confusing false negatives. Specifically, if you do this:
Have you asked Sourcetree or Git Tower to change their behavior instead? They can compute ahead/behind without setting tracking, and it seems like setting tracking is not really correct here (the local branches do not really "track" temporary remote CI branches in the traditional sense).
I'm not sure actually. Most of us use GUI tools like Sourcetree or Git Tower, which automatically set up tracking when a branch is pushed. I guess they do this to be able to show the "Commits behind / ahead" badges on branches.
Why does the local branch track the remote branch? Do you push using --set-upstream? If so, why?
I see the same behavior noted by @lianghu in T9042#129510.
Jul 21 2016
Excellent! Thanks for this so very detailed answer. I will try the way of the phid.lookup to work this issue around in the while.
Looks like that'll work nicely!
Thanks for the report, and for the good reproduction instructions. D16313 should raise a better exception.
There isn't enough information provided for us to reproduce this issue. See Contributing Bug Reports.
T5088 is a possible use case (report if the current revision needs an update), although I feel like it's a bit flimsy.
T10895 is a reasonable followup for --revision / --do-what-I-mean-instead-of-what-I-say.
I think we missed the window on this one.
The arc help land documentation was improved by T9657.
After T10431, aliases are also read from system configuration.
After the introduction of PhutilHTTPEngineExtension (T10227) we have a more viable pathway to bring support for this upstream, but I'd still like to see more interest in it before thinking about upstream support. It looks like only 1-2 installs would use it, today (not sure if both of you represent the same install or not).