#2 file object overwritten in plugins

open
nobody
None
5
2009-05-16
2009-05-16
No

Hi
just seen in plugins you overwrite the file object

def __call__(self, document, filename, file = None, options = None):
if options is None:
options = {}
try:
module = self.load_module()
except:
warn_tb(INTERNAL, 'When importing plugin %s', self.module_name)
raise SketchError(_("Cannot load filter %(name)s")
% {'name':self.module_name})
if file is None:
file = open(filename, 'w')
close = 1

Discussion


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks