[FIXED] Setting lamp distance through python bug

Hello,

I think currently there might be a bug with setting a lamp’s distance through python.

When using the official 2.71 release and newer builds (including today’s buildbot version hash 698a9a2), attempting to set a point (or spot) lamp’s distance sets the lamp’s energy instead.

I mainly use Ubuntu, but I’ve tested this on Win7 as well (both 32-bit) and get the same results.

It works for me as expected on 2.70a however.

I’ve attached a .blend file that shows what I’m describing.

lightDistanceBug.blend (402 KB)

The example uses a point lamp, but the results are the same if you change it to a spot lamp.

I’d appreciate it if someone else could verify this behavior as well (maybe on a 64-bit system or OSx), to confirm that it is in fact a bug and not something specific to my working environment, before I submit this to the bug tracker.

Thank you,
-Jon

EDIT:
Proposed a revision for this bug, and it has since been reviewed and committed to master [a21a9dd]

http://lists.blender.org/pipermail/bf-blender-cvs/2014-July/066297.html

Submitted this to the bug tracker.

T41204

-Jon

Went ahead and submitted a diff for the bug fix.

https://developer.blender.org/D689

Hope to get it reviewed.

-Jon

Tracked down the bug and proposed a revision.

It has since been reviewed and committed to master [a21a9dd]

http://lists.blender.org/pipermail/bf-blender-cvs/2014-July/066297.html

-Jon