beatreichenbach / realflare

Physically-Based Lens Flare Tool
57 stars 3 forks source link

AttributeError: 'NoneType' object has no attribute 'array' #56

Closed beatreichenbach closed 1 year ago

beatreichenbach commented 1 year ago

The tool currently errors out when no lens model is selected.

As reported in #51:

ERROR:root:'NoneType' object has no attribute 'array'
Traceback (most recent call last):
  File "/Users/afry/.pyenv/versions/3.10.8/lib/python3.10/site-packages/realflare/api/engine.py", line 227, in render
    render_func(project)
  File "/Users/afry/.pyenv/versions/3.10.8/lib/python3.10/site-packages/realflare/api/engine.py", line 116, in flare
    path_indexes = self.preprocess_task.run(project.flare, project.render)
  File "/Users/afry/.pyenv/versions/3.10.8/lib/python3.10/site-packages/realflare/api/tasks/preprocessing.py", line 76, in run
    areas = self.update_areas(rays)
  File "/Users/afry/.pyenv/versions/3.10.8/lib/python3.10/site-packages/realflare/api/tasks/preprocessing.py", line 46, in update_areas
    path_count, wavelength_count, ray_count = rays.array.shape
AttributeError: 'NoneType' object has no attribute 'array'
INFO:root:Engine.render:                              9.101ms
alexfry commented 1 year ago

Ahh excellent! This does run on the Mac now in that case!

image
beatreichenbach commented 1 year ago

This was addressed in https://github.com/beatreichenbach/realflare/releases/tag/v0.4.0