Comment 6 for bug 625365

Revision history for this message
Alexander Belchenko (bialix) wrote : Re: [Bug 625365] Re: bzr-explorer/bzr check of all repo when opening a simple folder

Alexandre Garnier пишет:
>>From my point of view, when I open 'repo/work' I would like to open only this folder, not all the repo.
> --> Explorer behavior should be to hide everything outside the folder I want to open.

Makes sense. But it's hard to read the user mind without optional python
module named "telepathy" :-) What if the user actually *want* open
entire repo and just missed the right folder?

> But I'm still wondering why opening a subfolder of a repo should scan *all* branches inside the repo.

Because that's how repo.find_branches() method currently implemented in bzr.

 > Isn't it possible to filter the scan on the subfolder ?

We need to write our own find_branches() implementation, I guess.

 > If I open this folder and not the repo it's because
 > I don't care about other branches of the repo.

See my the first comment. Sometimes you don't but sometimes you do.

> Opening a branch inside a repo doesn't scan the repo...

Because in this case bzr already has a branch and therefore explorer can
  open only it. There is 3 modes to open location in the explorer:

1) open branch/checkout -> no scan performed
2) open shared repo (with upward searching) -> scan for all nested
branches, checkouts, etc performed
3) open the plain directory without shared repo -> scan for all nested
branches, checkouts, repositories performed.

Your case is 2. The case 3 could be even slower, I guess.

I have a plan to change how the explorer opens locations. I want to put
the open process in the background to keep the UI responsive. Actually I
want to extract all accesses to bzr commands from explorer into separate
process (1 process for each branch/repo), something like Chrome browser
does. But this is the long term plan, and will require a lot of work.

I will try to invent some workaround for your situation in the short
term. Or maybe you have in mind something and going to write a patch?