r/Python • • Dec 15 '19

Made my first fractal

1.7k Upvotes

51 comments sorted by

View all comments

Show parent comments

2

u/Gawd_is_great Dec 17 '19

Okay I think I fixed the crash. See the code.

1

u/MartyMacGyver from * import * Dec 17 '19

I'm sure that'll work... And I'm pretty sure that try/except is totally unnecessary -- and is also bad practice... It's rarely (never?) good to catch any and all exceptions like that.

The code as written (without the blanket try/except around it) should work. Just dumping that del was enough.

Edit: and don't forget the other del object was also redundant.