[
https://issues.apache.org/jira/browse/THRIFT-3539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15959620#comment-15959620
]
ASF GitHub Bot commented on THRIFT-3539:
----------------------------------------
GitHub user jeking3 opened a pull request:
https://github.com/apache/thrift/pull/1242
THRIFT-3539: resubmitting PR #784 to get the fix qualified and merged
There was a comment in the Jira ticket this didn't work. Let's see what a
fresh build says. The author's original fork is gone, so I am shepherding this
through if it works.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/jeking3/thrift THRIFT-3539-resubmit
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/thrift/pull/1242.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1242
----
commit 146dcbd252576f7ad963c6fb93165150ff67ee3a
Author: James E. King, III <[email protected]>
Date: 2017-04-06T19:40:25Z
THRIFT-3539: resubmitting PR #784 to get the fix qualified and merged
----
> Use self.process_* instead of Processor.process_* in generated processor code
> -----------------------------------------------------------------------------
>
> Key: THRIFT-3539
> URL: https://issues.apache.org/jira/browse/THRIFT-3539
> Project: Thrift
> Issue Type: Bug
> Components: Python - Library
> Reporter: Thomas Bartelmess
>
> In our codebase we ended up overriding the process_* handlers because we had
> some special requirements, how exceptions are handled.
> in the __init__ function of processor the self._processMap refers to all the
> process_* functions on the Processor class.
> {code}
> def __init__(self):
> self._processMap = {}
> self._processMap = Processor.process_foo
> {code}
> The processor should refer to the functions using self, so when they are
> overridden in the subclass, the subclass implementation is used.
> {code}
> def __init__(self):
> self._processMap = {}
> self._processMap = self.process_foo
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)