Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lightingManager.py not loading .json correctly #2

Open
ukkodesign opened this issue Sep 16, 2019 · 1 comment
Open

lightingManager.py not loading .json correctly #2

ukkodesign opened this issue Sep 16, 2019 · 1 comment

Comments

@ukkodesign
Copy link

Received the following error when loading the .json file in Maya2019 (Product version: 2019.0.0.F) from C:/Users/<user>/Documents/maya/lightManager\lightFile_0916.json

# Traceback (most recent call last):
#   File "C:/Users/oleu/Documents/maya/2019/scripts\lightingManager.py", line 178, in importLights
#     self.setButtonColor()
# AttributeError: 'NoneType' object has no attribute 'intensity'

.json extendson changed to .txt
lightFile_0916.txt

I coded along with the videos and had no errors up until video "69. Importing Our Lights".
Went back and checked my code against yours. Still didn't work. I loaded your example file and the same error was returned.
Not sure if its something that's changed in Maya 2019 or Python/ PyMel/ Qt/ etc. syntax, or if it's a system specific/ user error (probably the later).
Thanks!

@dgovil
Copy link
Owner

dgovil commented Sep 17, 2019

The error seems to be coming from when the code tries to set the light intensity and for some reason the light object doesn't have an intensity attribute.

After creating the light, can you print out the light and also type(light) to see what you get back?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants