cmbant/getdist

TypeError: 'NoneType' object is not callable

Closed this issue · 4 comments

Hi.
I just copy the sample from the website "https://getdist.readthedocs.io/en/latest/plot_gallery.html" to the Pycharm on my MacBook pro with M2 core. But an error occurred when it runs to
"g = plots.get_subplot_plotter()
g.triangle_plot([samples, samples2], filled=True)" .

The error is :
/Users/miniforge3/envs/test_tf/bin/python3.9 /Users/PycharmProjects/LamostBinary/src/test.py
GetDist Version: 1.4, Matplotlib version: 3.5.2
Removed no burn in
Removed no burn in
Exception ignored in: <function GetDistPlotter.del at 0x159e673a0>
Traceback (most recent call last):
File "/Users/liujunhui/miniforge3/envs/test_tf/lib/python3.9/site-packages/getdist/plots.py", line 726, in del
File "/Users/liujunhui/miniforge3/envs/test_tf/lib/python3.9/site-packages/getdist/_base.py", line 38, in getattribute
TypeError: 'NoneType' object is not callable

Thank you.

Weird, does it work outside PyCharm (I think they did introduce a few debugging oddities in a recent update). Hard to see how "_map_name" could be None, given the function is defined in the same file just above. It works OK in pycharm for me though.

It also returns the same error in my terminal on Mac OS. But it can work well on my Ubuntu server. So is it possible that the error is caused by M2 chip?

Could be some python library bug I guess. Does it work if you comment out the del function? Could try a clean python 10 or 11 environment.

Closing absent any further information