Open mrspiderbrain opened 1 year ago
Assuming you've resolved this issue by now. If the issue persists, and updating Lando does not resolve it, please re-open this issue and provide more details.
I just initiated a new D10 project and the same problem is still there.
Steps to reproduce
Current workaround - switch to master branch immediately after the lando init. If changes get lost - switch to master branch on local, merge main into master and then push.
@ethangeorgi it doesn't look like I have permission to reopen this issue.
I did replicate this and took a look into the code. AFAIK, Lando doesn't do anything "extra" to set the default remote branch when initializing a project.
Instead, the problem seems to be that Pantheon has chosen main
as the default branch for its Drupal 10 upstream (see https://github.com/pantheon-upstreams/drupal-10-composer-managed for example), but is still using master
to drive its workflows. Most of the other (older) upstreams seem to use master
. This is reinforced by Pantheon's cut-and-paste git clone
command for Drupal 10 sites specifying -b master
.
Lando's lando pull/push
commands do use master
by default. A potential solution could be having Lando checkout master and set it as the default after cloning the repo or possibly passing in the -b master
option to get-remote-url.sh
, which I think accepts options. I'm a little conflicted on whether that's appropriate or not considering we're basically handling an inconsistency of the Pantheon platform, would definitely entertain the PR though.
@reynoldsalec I agree that Pantheon should fix this given your analysis. I'll open a pantheon support ticket and point to this ticket for reference so they get the chance to fix it their end.
I've made a customer support ticket, not public but the ID is 925842 for general reference. It would be good if we could leave this ticket open until we get some info from Pantheon on what they intend to do.
Sounds good, thanks for following up on it @mrspiderbrain!
Currently lando init pantheon recipe fails. Default to main branch which does not connect to the cloud build process. Pantheon are planning to move to "main" but not yet.