Some silly confusion with shadow sample

I don’t understand… I always run Panda samples from their Start menu shortcuts. From Start menu they run fine. This time I opened it in Notepad++ and tried to run with Panda’s python. And it doesn’t run!

Traceback (most recent call last):
  File "C:\Panda3D-1.5.3\samples\Shadows\Tut-Shadow-Mapping.py", line 228, in <module>
    World()
  File "C:\Panda3D-1.5.3\samples\Shadows\Tut-Shadow-Mapping.py", line 145, in __init__
    lci.setShader(Shader.load('caster.sha'))
TypeError: NodePath.setShader() argument 1 must be Shader, not NoneType

I am doing something very silly, I know, but can’t figure out what…

If I change the original code:

lci.setShader(Shader.load('caster.sha'))

into new code:

lci.setShader(loader.loadShader("caster.sha"))

(and all other instances of “Shader.load()”) then everything works fine. Why so? Is Shader.load() depreciated?

I suspect Shader.load doesn’t use model path config var search path. Using loader is the correct way.