client_python
client_python copied to clipboard
Error: TypeError: expected str, bytes or os.PathLike object, not NoneType
Sometimes i get this error:
Traceback (most recent call last):
File "/opt/homebrew/Cellar/[email protected]/3.10.15/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/process.py", line 314, in _bootstrap
self.run()
File "/opt/homebrew/Cellar/[email protected]/3.10.15/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "/opt/homebrew/lib/python3.10/site-packages/django_q/cluster.py", line 165, in __init__
self.start()
File "/opt/homebrew/lib/python3.10/site-packages/django_q/cluster.py", line 174, in start
self.guard()
File "/opt/homebrew/lib/python3.10/site-packages/django_q/cluster.py", line 315, in guard
self.reincarnate(p)
File "/opt/homebrew/lib/python3.10/site-packages/django_q/cluster.py", line 234, in reincarnate
prometheus_multiprocess.mark_process_dead(process.pid)
File "/opt/homebrew/lib/python3.10/site-packages/prometheus_client/multiprocess.py", line 169, in mark_process_dead
for f in glob.glob(os.path.join(path, f'gauge_{mode}_{pid}.db')):
File "/opt/homebrew/Cellar/[email protected]/3.10.15/Frameworks/Python.framework/Versions/3.10/lib/python3.10/posixpath.py", line 76, in join
a = os.fspath(a)
TypeError: expected str, bytes or os.PathLike object, not NoneType
It happen here:
https://github.com/django-q2/django-q2/blob/337a5782d9113a6e9d058743488e7517aebb8280/django_q/cluster.py#L233-L234
When mark_process_dead
is called.
Can you help me?
Thanks.