web server does not work cyberpanel - emergency help me

Hi,

I wanted to update because SSL does not work and I installed python 3.7, but I think the cyberpanel crashed gives errors and does not open the site.
Traceback (most recent call last):
File “upgrade.py”, line 2109, in
main()
File “upgrade.py”, line 2105, in main
Upgrade.upgrade()
File “upgrade.py”, line 2020, in upgrade
Version = version.objects.get(pk=1)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/manager.py”, line 85, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/query.py”, line 373, in get
num = len(clone)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/query.py”, line 232, in len
self._fetch_all()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/query.py”, line 1102, in _fetch_all
self._result_cache = list(self._iterable_class(self))
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/query.py”, line 53, in iter
results = compiler.execute_sql(chunked_fetch=self.chunked_fetch)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/sql/compiler.py”, line 863, in execute_sql
sql, params = self.as_sql()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/sql/compiler.py”, line 420, in as_sql
where, w_params = self.compile(self.where) if self.where is not None else ("", [])
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/sql/compiler.py”, line 373, in compile
sql, params = node.as_sql(self, self.connection)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/sql/where.py”, line 79, in as_sql
sql, params = compiler.compile(child)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/sql/compiler.py”, line 373, in compile
sql, params = node.as_sql(self, self.connection)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/lookups.py”, line 169, in as_sql
lhs_sql, params = self.process_lhs(compiler, connection)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/lookups.py”, line 162, in process_lhs
db_type = self.lhs.output_field.db_type(connection=connection)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/models/fields/init.py”, line 640, in db_type
return connection.data_types[self.get_internal_type()] % data
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/utils/functional.py”, line 35, in get
res = instance.dict[self.name] = self.func(instance)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/mysql/base.py”, line 174, in data_types
if self.features.supports_microsecond_precision:
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/utils/functional.py”, line 35, in get
res = instance.dict[self.name] = self.func(instance)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/mysql/features.py”, line 53, in supports_microsecond_precision
return self.connection.mysql_version >= (5, 6, 4) and Database.version_info >= (1, 2, 5)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/utils/functional.py”, line 35, in get
res = instance.dict[self.name] = self.func(instance)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/mysql/base.py”, line 385, in mysql_version
with self.temporary_connection() as cursor:
File “/usr/lib64/python2.7/contextlib.py”, line 17, in enter
return self.gen.next()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 591, in temporary_connection
cursor = self.cursor()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 254, in cursor
return self._cursor()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 229, in _cursor
self.ensure_connection()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 213, in ensure_connection
self.connect()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/utils.py”, line 94, in exit
six.reraise(dj_exc_type, dj_exc_value, traceback)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 213, in ensure_connection
self.connect()
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/base/base.py”, line 189, in connect
self.connection = self.get_new_connection(conn_params)
File “/usr/local/CyberPanel/lib/python2.7/site-packages/django/db/backends/mysql/base.py”, line 274, in get_new_connection
conn = Database.connect(**conn_params)
File “/usr/lib64/python2.7/site-packages/MySQLdb/init.py”, line 81, in Connect
return Connection(*args, **kwargs)
File “/usr/lib64/python2.7/site-packages/MySQLdb/connections.py”, line 193, in init
super(Connection, self).init(*args, **kwargs2)
django.db.utils.OperationalError: (2002, ‘Can\‘t connect to local MySQL server through socket \’/var/lib/mysql/mysql.sock\’ (2 “No such file or directory”)’

If you installed python 3.7 to be system default, try new upgrade guide → Upgrading CyberPanel - CyberPanel

It will install python 2.7 separately.