Issue by: switching from production to development environment

Hey Guys,

I’am trying switching from production to development environment, because creating an app is not working. An user told me, that it is looking like I’am using a production environment of ERPNext, an I have to switch to the development environment.

Now I get this issue by trying sudo bench switch-to-develop:

bench@erpnext:/home/bench/frappe-bench$ sudo bench switch-to-develop
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 11, in
load_entry_point(‘bench’, ‘console_scripts’, ‘bench’)()
File “/home/bench/.bench/bench/”, line 41, in cli
File “/usr/local/lib/python3.8/dist-packages/click/”, line 764, in call
return self.main(*args, **kwargs)
File “/usr/local/lib/python3.8/dist-packages/click/”, line 717, in main
rv = self.invoke(ctx)
File “/usr/local/lib/python3.8/dist-packages/click/”, line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/local/lib/python3.8/dist-packages/click/”, line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/usr/local/lib/python3.8/dist-packages/click/”, line 555, in invoke
return callback(*args, **kwargs)
File “/home/bench/.bench/bench/commands/”, line 56, in switch_to_develop
switch_to_develop(apps=[‘frappe’, ‘erpnext’])
File “/home/bench/.bench/bench/”, line 423, in switch_to_develop
switch_branch(‘develop’, apps=apps, bench_path=bench_path, upgrade=upgrade)
File “/home/bench/.bench/bench/”, line 381, in switch_branch
repo = git.Repo(app_dir)
File “/usr/local/lib/python3.8/dist-packages/git/repo/”, line 183, in init
raise InvalidGitRepositoryError(epath)
git.exc.InvalidGitRepositoryError: /home/bench/frappe-bench/apps/frappe

please help

Hello @Juri

Could you put up what steps have you done when you created the frappe-bench?



Installing with this tutorial

Step 6

Try this

  • sudo bench switch-to-branch version-13-beta frappe erpnext --upgrade
  • sudo bench update --patch

Hello @Juri
Production environment starts at step 8. What do you have so far with not being able to create an app using the steps 6 and 7?