Broken after bench update

I was on V12. I don’t recall the last time I updated, but it has probably been within the last two months. I updated today as I saw a message when I logged in that there was an update. Now my system is broken! I’m stuck on the “Sorry! We will be back soon” page. I see there’s some error (“invalid syntax”) during the last part of the update:

Is something broken in the update?

Thanks.

Another weird thing is that I type “bench version” and get “Error: No such command “version””. When did that change? If I type “bench --help”, I see the list of bench commands and version is not one of them.

There are merge conflicts in the code. reset the branch to HEAD and then run bench update.

Would you mind showing me the syntax to do that so I make sure to do it right?

Curious, what would have caused the merge conflicts?

git reset --hard HEAD

I went into the apps/frappe folder and ran the “git reset --hard HEAD” command (I had to do some digging to know that was the folder to execute it in … at least that’s what I think it’s supposed to be).

But now I’m getting an “INTERNAL SERVER ERROR” page when trying to load ERPNext!

Here’s what happened after doing “bench update”:

Now what??!

Okay, so it’s working again. For anyone that’s encountering what I did, here’s what worked for me:

  1. Go into the apps/frappe folder and run the “git reset --hard HEAD”
  2. Run “bench update --reset” in the frappe-bench folder

After running “bench update” the first time after doing the git reset command, things were broken. I had to re-run the git reset command and then the bench update WITH the --reset to get it working again.

I have no idea what broke and why. I don’t think I did anything that would have caused it. But thank you @hrwx - I wouldn’t have figured it out without the bread crumbs you dropped.

3 Likes