cpenv / tk-cpenv

Shotgun Toolkit Application that adds support for cpenv modules.
Other
20 stars 6 forks source link

[BUG] Empty environment causes GUI to break #22

Closed RicardoMusch closed 2 years ago

RicardoMusch commented 2 years ago

When an empty environment for the engine to be loaded exists in the current project the choice menu breaks.

Steps to reproduce:

  1. Make two environments for a software, example Nuke and Nuketest - tk-nuke
  2. Add modules to Nuke but none to Nuketest
  3. Launch Nuke
  4. The Popup UI will break with the following error:
Traceback (most recent call last):
  File "C:\Users\ricardom\AppData\Roaming\somepath\p815c2015.basic.desktop\cfg\install\core\python\tank\platform\engine.py", line 1686, in _create_widget
    widget = derived_widget_class(*args, **kwargs)
  File "S:\_cache\shotgrid\bundle_cache\github\cpenv\tk-cpenv\v0.5.10\python\cpenv_ui\env_selector.py", line 42, in __init__
    + '\n'.join(environment['sg_requires'].split())
AttributeError: 'NoneType' object has no attribute 'split'

image

danbradham commented 2 years ago

Thanks for reporting @RicardoMusch.