Anvil Community Forum

[Beta] Unexpected branch change when adding data table

I was working on a branch other than master. I created a new Data Table and added some columns to it. This seems to have (automatically, without notifying me) switched me back into editing the master branch, leading to confusion about why some recent changes (on the non-master branch I thought I was on) seemed to have disappeared.

Did you merge to master?
Every time you merge to master, it automatically switches to master.

No, I had not merged to master.

What I think that must have happened is that since you didn’t edit anything, when the editor auto-save clock ticked, it didn’t commit to anything and auto-changed back to master.

If you create a new branch from master, do nothing and refresh the page the editor will load using master, not the new branch. The editor (I think) don’t know which was the last branch used, only the last commit made and which branch is associated with it. Since the last real edit in code was master, it changed back to master.

1 Like

3 posts were merged into an existing topic: [Beta] Make it difficult (or impossible) to mess up the master branch

Well, I’m not able to replicate this by monkeying with Data Tables in a test app, so maybe it was something else I did.

I’m also not able to replicate this, though. Maybe it was changed recently, but the editor now seems to remember the last branch I had open.

1 Like