I have existing installation of Frappe Bench and various app like ERPNext, Payments, HRMS, etc.
Now I have to install India Compliance. When I try to install it using the command `bench get-app --branch version-15 https://github.com/resilient-tech/india-compliance.git\` it gave error that cannot install on current Frappe version and I need to update.
So I ran the command bench update. This command went through and all the apps got updated. Now when I try to run even simple commands like bench list-apps I get errors.
Traceback (most recent call last):
File "/usr/local/bin/bench", line 8, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.10/dist-packages/bench/cli.py", line 74, in cli
cmd_from_sys = get_cmd_from_sysargv()
File "/usr/local/lib/python3.10/dist-packages/bench/utils/__init__.py", line 606, in get_cmd_from_sysargv
if sys_argv.index(arg) == 0 and arg in Bench(".").apps:
File "/usr/local/lib/python3.10/dist-packages/bench/bench.py", line 69, in __init__
self.apps = BenchApps(self)
File "/usr/local/lib/python3.10/dist-packages/bench/bench.py", line 183, in __init__
self.set_states()
File "/usr/local/lib/python3.10/dist-packages/bench/bench.py", line 188, in set_states
self.states = json.loads(f.read() or "{}")
File "/usr/lib/python3.10/json/__init__.py", line 346, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.10/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.10/json/decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting ',' delimiter: line 71 column 5 (char 1760)
I found the issue. The apps.json file had a missing comma between two apps.
Actually while trying to install another app called Exim Bench command was failing so I manually fetched the app from Github and then added it manually. In the process by mistake a command between apps entries got delete.