Python Scripts not on Menus?

I recently noticed that some of my python scripts weren’t showing upon the python scripts menu in Blender, their in the scripts folder they just won’t appear on the menu. I’ve tried reloading the menu and re-installing the scripts but nothings working. I’m not quite sure why some show up and others don’t, for example I recently added the demolition script and it works fine, but when I tried to re-add the 3DS import script it wouldn’t show. I can still run the scripts with the text editor by loading them from the scripts directory but it would be easier If I didn’t have too. I’m running Blender 2.44 on Ubuntu.
Any help is appreciated.

Check the first few lines of each script, they should be a header as follows:

#!BPY

“”"

Name: ‘Break’

Blender: 245

Group: ‘Mesh’

Tooltip: ‘Breaking up mesh into multiple objects.’

“”"

With name, Blender version that works for the script, menu group from which you call them and a tooltip.

This header is necessary for Blender to register the script for the script menus.

The header is their but says Blender: 241. Some of the other scripts which do show up also say older versions of blender (mostly 243) and still work fine but others with 243 as well don’t show up. The rest of the header is the same.

Hi all. I’ve the same problem, no matter which os or version- i’m crazy with that, it seems not to exist any reason. It’s crazy, and it isn’t the first time.

Well, I’ve Xubuntu. Yesterday, I moved the ‘scripts’ folder outside ‘.blender’ one. Then I restored it to its location. Well, at the end… Just some of the scripts are shown at the menus. SOME they are, and THE REST not. You may examine one of each, and they have the same owners, permissions, locations, configurations, versions… the only I get was to copy one of them, saving it with a different name, and magickly… appear! Then I deleted the original, renamed the new as the old, and dissapeared again.
As I said, it happened to me in different computers, os and blender versions.
I also deleted the BpyMenus file, but it appear again with the same extrange behaviour.

There’s a way to find out what’s wrong when loading scripts:

  1. Start Blender from a terminal window with the -d command line parameter, like:
    blender -d

  2. Change one Blender window to “Scripts Window”. Do “Scripts -> Update Menus” from the menu header of the scripts window.

  3. Watch the terminal output. If there’s something wrong with any script, there should be a message about it.

Yeah! Well, that’s the error it reports:

BPyMenus Error: max depth reached traversing dir tree
:spin:

So I’m confusing yet… too many dirs levels???

EDIT:
That’s all, I’ve just found the answer here:
http://blenderartists.org/forum/showthread.php?t=66794
it must be a duplicated script name, reinstalling scripts dir and being more careful… :stuck_out_tongue:

After i posted, I found a duplicate name entry of two scripts that come with Blender, in my svn version. I don’t know if it’s also in the scripts for 2.47, but it’s worth a look. I already reported this error and it’s fixed in svn now.

Look for the two scripts:
scripttemplate_ipo_gen.py
scripttemplate_camer_object.py

They have the same header. The corrected header for scripttemplate_ipo_gen.py is

#!BPY
"""
Name: 'IPO Example'
Blender: 245
Group: 'ScriptTemplate'
Tooltip: 'Script template for setting the IPO'
"""