mitsuba-renderer / mitsuba3

Mitsuba 3: A Retargetable Forward and Inverse Renderer
https://www.mitsuba-renderer.org/
Other
2.1k stars 246 forks source link

Fix Python ScopedThreadEnvironment #1264

Closed dvicini closed 3 months ago

dvicini commented 3 months ago

This fixes #1263. The issue was the missing "_a.none()" annotation for Nanobind. The naming of the parameters to __exit__ follows what Dr.Jit itself uses. I also added a new test that covers that at least using a thread environment does not fail.

njroussel commented 3 months ago

Hi @dvicini

This looks good!

(Ignore the CI for now, looks like it's stuck/broken because of recent update of nanobind. I'll retrigger it manually, once I figure what's going on.)