whenever I try to print thing with a list (or maby some others also) as returntype Blender2.23 crashes and Blender 2.22&2.21 just print “[” in the shell window and leave it there… after that no output is shown in the shell window even if the script is run again… python version is 2.1.1…
for example:
import Blender
print Blender.Object.Get() #should get a list of the objects in the scene “[…][…][…]…”
but in shell window just…
[
am I missing something here…? :-? or is this just a stupid no-can-do-bug or something…?
I have the same problem on one of my computers…One thing that i may suggest is downloading and installing the full python package from www.python.org…Im not certain if that will fix it, but the computer that it happens to me with is the one that doesn’t have it installed.
That thing where it stops printing is a pain…but i you purposely cause an error at the end of the file everything that you tried to print before it is finally printed out.
Kurppa: As far as I know, printing objects returned by the Blender modules often hang the console. Installing a full Python distro will not change anything (btw, you should use Python 2.01, not 2.11 since Blender is based on Python 2.0).
You should try one of these:
import Blender
ObList = Blender.Object.GetSelected()
for Ob in ObList:
print Ob.name
import Blender
ObList = Blender.Object.GetSelected()
for Ob in ObList:
print str(Ob)
import Blender
ObList = Blender.Object.GetSelected()
for Ob in ObList:
print repr(Ob)