dolt icon indicating copy to clipboard operation
dolt copied to clipboard

Deleting branch causes error in another session if that branch is active

Open tbantle22 opened this issue 3 years ago • 0 comments

If I delete a branch that's the active branch in other session, I get stuck with a branch not found and I can't use any procedures to check out another branch.

To repro:

In session 1:

mysql> call dolt_checkout("-b", "testbranch");
+--------+
| status |
+--------+
|      0 |
+--------+
1 row in set (0.05 sec)

In session 2:

mysql> call dolt_branch("-D", "testbranch");
+--------+
| status |
+--------+
|      0 |
+--------+
1 row in set (0.05 sec)

In session 1 (dolt_status should fail, but I think I should be able to check out a branch that does exist):

mysql> select * from dolt_status;
ERROR 1105 (HY000): branch not found
mysql> call dolt_checkout("main");
ERROR 1105 (HY000): branch not found

Workaround is checking out another branch by using use db/main

tbantle22 avatar Sep 16 '22 18:09 tbantle22