Hi, everyone!
I have come across this error while testing the Sea Level Predictor assignment:
`ERROR: test_plot_lines (test_module.LinePlotTestCase)
Traceback (most recent call last):
File “/home/runner/boilerplate-sea-level-predictor/test_module.py”, line 33, in test_plot_lines
actual = self.ax.get_lines()[0].get_ydata().tolist()
AttributeError: ‘list’ object has no attribute ‘tolist’`
It seems that the test module retrieves a list by assigning actual
to self.ax.get_lines()[0].get_ydata()
and it is impossible to apply tolist()
function to it. But I have no idea why this happens.
Here’s my repl:
I’ll be glad for any help.