Page MenuHomePhabricator

Changing repository from hosted to fetched fails
Closed, ResolvedPublic

Assigned To
Authored By
fooishbar
Apr 29 2016, 6:51 AM
Referenced Files
F1251041: Screen Shot 2016-04-29 at 6.44.27 AM.png
Apr 29 2016, 1:49 PM
F1251037: Screen Shot 2016-04-29 at 6.42.32 AM.png
Apr 29 2016, 1:49 PM
F1251043: Screen Shot 2016-04-29 at 6.45.37 AM.png
Apr 29 2016, 1:49 PM
F1251035: Screen Shot 2016-04-29 at 6.42.18 AM.png
Apr 29 2016, 1:49 PM
F1251052: Screen Shot 2016-04-29 at 6.48.45 AM.png
Apr 29 2016, 1:49 PM
F1251033: Screen Shot 2016-04-29 at 6.41.40 AM.png
Apr 29 2016, 1:49 PM
F1251039: Screen Shot 2016-04-29 at 6.43.48 AM.png
Apr 29 2016, 1:49 PM
F1251049: Screen Shot 2016-04-29 at 6.46.47 AM.png
Apr 29 2016, 1:49 PM

Description

  • Create a hosted repository in Diffusion
  • Realise that was the wrong thing to do
  • Edit the repository and change it to imported
  • Get asked if you'd like to mirror it
  • Never get asked what the source URI is
  • Repository is now useless

Running 2016.16 stable (plus a bunch of local changes, but none relevant to Diffusion).

Event Timeline

I can't reproduce this. Here's what I tried. First, I created a new, empty, hosted Git repository:

Screen Shot 2016-04-29 at 6.41.40 AM.png (1×1 px, 218 KB)

Then, I clicked Edit Hosting. I selected Host Repository Elsewhere and clicked Save and Continue.

Screen Shot 2016-04-29 at 6.42.18 AM.png (1×1 px, 175 KB)

On the next screen, I turned off hosting from both the protocols, since I don't want anyone fetching this repository from Phabricator. Then, I clicked Save Changes.

Screen Shot 2016-04-29 at 6.42.32 AM.png (1×1 px, 204 KB)

Since I haven't configured a remote yet, I now saw an "Update Error" in the status section:

Screen Shot 2016-04-29 at 6.43.48 AM.png (458×1 px, 64 KB)

I scrolled down past "Mirrors" to "Remote", so I could configure a remote. I didn't see any prompts to add mirrors (I don't think we have any in the product). I clicked Edit Remote.

Screen Shot 2016-04-29 at 6.44.27 AM.png (440×1 px, 42 KB)

I provided the remote URI of a repository I wanted to import, and clicked Continue.

Screen Shot 2016-04-29 at 6.45.37 AM.png (1×1 px, 160 KB)

In this case, my remote did not require any credentials, so I declined to provide credentials on the next step. I clicked Save.

Screen Shot 2016-04-29 at 6.46.32 AM.png (1×1 px, 150 KB)

The remote section now showed the new configured remote:

Screen Shot 2016-04-29 at 6.46.47 AM.png (122×1 px, 15 KB)

After a few moments, the repository imported and the status UI showed it was successful:

Screen Shot 2016-04-29 at 6.48.45 AM.png (101×607 px, 20 KB)

I clicked back up a level and browsed my newly imported repository:

Screen Shot 2016-04-29 at 6.49.25 AM.png (1×1 px, 286 KB)

What can I do differently to reproduce the issue you encountered?

Note that when you do this, you may generate a large amount of email you don't want, because you're adding commits to a repository which was previously marked as fully imported (it "completed" the import process when it was an empty, hosted repository). You may want to disable publishing in "Publish/Notify". See also T9554.

This workflow is also changing soon, in association with T10748 / T10366. These changes won't take effect for at least one more week, though.

@epriestley Thanks for the thorough response. I guess it's probably been fixed in intermediate revisions, and as you say, it is all changing pretty dramatically anyway, so no big deal: as it was a newly-created repository, I just scrapped it and created anew.

[edit: No, I'm wrong, I'd just wholly failed to spot the 'edit remote' section, and was used to that being part of the setup process.]

@epriestley Is there a way to disable T9554's heuristics? With patchsets of 30+ patches which get pushed in a single atomic bundle, we don't want to go back to import mode and lose all notifications.

The heuristic only triggers if the repository was previously empty. So it might possibly get a false positive on the very first pull request to a new empty repository, but should be fine after that.

I may add some controls to tailor this behavior more narrowly, but I think it should get things right almost all the time.

epriestley claimed this task.