Page MenuHomePhabricator

On branch "xyz", "arc land --onto xyz abc" does not result in update to "xyz" even when "xyz" is not ahead of the remote
Closed, ResolvedPublic

Description

The following arc land command was run from the develop branch which is what is being landed to. There are no other changes on develop that aren't already on the remote. arc land does land the T982 branch to origin/develop, but doesn't pull develop so I have to do that on my own. Not a huge deal, but could cause some confusion.
When I run arc land on the actual branch to be landed then things work as expected.

Output below:

reuben@devworkstation1:~/konekt-rest-api$ arc land T982                          
 TARGET  Landing onto "develop", selected by "arc.land.onto.default" configuratio
n.                                                                               
 REMOTE  Using remote "origin", the default remote under git.                    
 FETCH  Fetching origin/develop...                                               
This commit will be landed:                                                      
                                                                                 
      - bde3dd3 Correct issue with shipping method on receipts                   
                                                                                 
Landing revision 'D683: Correct issue with shipping method on receipts'...       
 BUILDS PASSED  Harbormaster builds for the active diff completed successfully.  
 PUSHING  Pushing changes to "origin/develop".                                   
Counting objects: 21, done.                                                      
Delta compression using up to 2 threads.                                         
Compressing objects: 100% (5/5), done.                                           
Writing objects: 100% (5/5), 616 bytes | 0 bytes/s, done.                        
Total 5 (delta 3), reused 0 (delta 0)                                            
To ssh://vcs-user@phabricator.konektdata.com/diffusion/API/konekt-rest-api.git   
   2c3b3f6..07281b4  07281b40e624a9eca73966dbb995b0378ff0922d -> develop         
 RESTORE  Switching back to "develop".                                           
Cleaning up branch "T982"...                                                     
(Use `git checkout -b T982 bde3dd3a9e5a82b51966acf0f9787d9fe4302f98` if you want 
it back.)                                                                        
 DONE  Landed changes.                                                           
reuben@devworkstation1:~/konekt-rest-api$ git status                             
On branch develop                                                                
Your branch is behind 'origin/develop' by 1 commit, and can be fast-forwarded.   
  (use "git pull" to update your local branch)                                   
                                                                                 
nothing to commit, working directory clean

Event Timeline

This has tripped me up a few times (maybe since arc was made great again?) and I think it happens when you do arc land foo instead of arc land in foo.

Yes, I think that's what I've observed as well.

This has tripped me up a few times (maybe since arc was made great again?) and I think it happens when you do arc land foo instead of arc land in foo.

More precisely, the branch is pulled when the branch you're landing is the current branch. I find it unintuitive that the branch is not pulled when the branch you're landing to is the current branch.

epriestley renamed this task from Arcanist not always pulling landed branch to On branch "xyz", "arc land --onto xyz abc" does not result in update to "xyz" even when "xyz" is not ahead of the remote.Oct 25 2019, 6:17 PM
epriestley triaged this task as Wishlist priority.
epriestley removed a project: Bug Report.
epriestley claimed this task.
epriestley added a subscriber: epriestley.

I'm not 100% sure I got this, but all of these seem to work now:

  • git checkout master; arc land feature1
  • git checkout feature1; arc land feature1
  • git checkout the-moon; arc land feature1

See T13546 and T13547, more broadly.