esdc-ce icon indicating copy to clipboard operation
esdc-ce copied to clipboard

Upgrade to python 3

Open YanChii opened this issue 5 years ago • 5 comments

Related items:

  • upgrade Django
  • upgrade Celery
  • upgrade other requirements, especially #466, #475, #476

The main project is deployed on mgmt01 and all nodes. Part of this upgrade is

  • upgrade /opt/local to newest LTS (19Q4)
  • upgrade envs
  • automate the upgrade process for current installations

YanChii avatar Mar 05 '20 10:03 YanChii

Work in progress... Partial results in upgrade-python3 branch... @YanChii if you find any issues please leave in comment.

ricco386 avatar Sep 09 '20 21:09 ricco386

[2020-09-20 21:33:10,255: ERROR/MainProcess] api.node.sysinfo.tasks.node_sysinfo_cb[7e7u1-cdefd1dd-67a8-43e5-8498]: Unicode-objects must be encoded before hashing
Traceback (most recent call last):
  File "/opt/erigones/api/node/sysinfo/tasks.py", line 181, in node_sysinfo_cb
    NodeSystemRestarted(node, system_version=node.system_version).send()
  File "/opt/erigones/api/system/node/events.py", line 14, in __init__
    task_id = task_id_from_string(node.owner.id, dummy=True, dc_id=DEFAULT_DC, tt=TT_DUMMY, tg=TG_DC_UNBOUND)
  File "/opt/erigones/que/utils.py", line 65, in task_id_from_string
    return task_prefix + '-' + hashlib.md5(user_id).hexdigest()[-8:] + x[8:-13]
TypeError: Unicode-objects must be encoded before hashing

YanChii avatar Sep 20 '20 21:09 YanChii

Browser console errors.

Uncaught SyntaxError: expected expression, got '<'

It is probably causing the "Please wait" loading window keeps appearing indefinitely.

YanChii avatar Sep 20 '20 21:09 YanChii

I have just push a few changes that should fix this and few more others I have found so far it looks good, but needs test everywhere...

ricco386 avatar Sep 30 '20 19:09 ricco386

Just a remark

/opt/erigones/vms/models/vm.py:962: RemovedInDjango19Warning: SortedDict is deprecated and will be removed in Django 1.9

YanChii avatar Nov 17 '20 21:11 YanChii