Strange. Python seems utterly confused. Can you:
1) Close Gimp, and restart it
2) Image>New
3) Add a couple of brushstrokes on the Backrgound layer
4) Start the Python console (Filters>Python-Fu>Console)
5) Copy/paste this code in the console (line by line)
And if there is an error on a line, report the line?
Btw what exact version of Gimp are you running?
1) Close Gimp, and restart it
2) Image>New
3) Add a couple of brushstrokes on the Backrgound layer
4) Start the Python console (Filters>Python-Fu>Console)
5) Copy/paste this code in the console (line by line)
Code:
image=gimp.image_list()[0]
layer=image.active_layer
pdb.gimp_drawable_desaturate(layer,DESATURATE_LUMINANCE)
pdb.plug_in_gauss_rle2(image,layer,0.,0.)
mask=pdb.gimp_channel_new_from_component(image, CHANNEL_GRAY,'Engraving Mask')
image.add_channel(mask)
And if there is an error on a line, report the line?
Btw what exact version of Gimp are you running?