En Tue, 04 Oct 2011 07:32:41 -0300, Wong Wah Meng-R32813 <r32...@freescale.com> escribió:

Haha... yeah I reviewed the code, it is supposed to exposed some remote methods locally (RMI proxy usage). However, I am not sure why what it does is merely a pass.

I commented out this code and haven't seen any negative implication. I will look into this again if I am convinced the next error I see is due to I commented out this code.

  exec('def %s(self, *args, **kw): pass'%methodStrName)

In case you convince yourself that defining this dynamic but empty function is really needed, you can avoid exec this way:

  def some_function(...)

    ...
    # instead of exec('def ...' % methodStrName)
    def empty_function(self, *args, **kw): pass
    empty_function.func_name = methodStrName
    ...
    # presumably methodStrName is referred somehow in
    # the remaining code block, or perhaps locals();
    # modify accordingly


--
Gabriel Genellina

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to