B
B
bQ12019-09-17 12:23:34
Django
bQ1, 2019-09-17 12:23:34

Error with python on django migrations?

Exception ignored in: <function WeakValueDictionary.__init__.<locals>.remove at 0x7fe1cf222400>
Traceback (most recent call last):
  File "/usr/lib/python3.5/weakref.py", line 117, in remove
TypeError: 'NoneType' object is not callable
Exception ignored in: <function WeakValueDictionary.__init__.<locals>.remove at 0x7fe1cf222400>
Traceback (most recent call last):
  File "/usr/lib/python3.5/weakref.py", line 117, in remove
TypeError: 'NoneType' object is not callable

What the hell?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrew, 2019-09-17
@bQ1

Migration has nothing to do with it.
https://bugs.python.org/issue29519
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=...

This seems to be fixable.
In short open /usr/lib/python3.5/weakref.py and change line 109 to:
def remove(wr, selfref=ref(self), _atomic_removal=_remove_dead_weakref):
And line 117 to:
_atomic_removal(d, wr.key)
Note you need to do this with spaces, not tabs as this will cause other errors.

https://github.com/ayufan-rock64/linux-build/issues/136

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question