Jython

Message3229

Author leosoto
Recipients leosoto
Date 2008年06月06日.02:44:11
SpamBayes Score 0.0
Marked as misclassified No
Message-id <1212720252.24.0.543432630334.issue1047@psf.upfronthosting.co.za>
In-reply-to
Content
While I suspect that the root of the problem is the sax parser output
not conforming with what pulldom expects, changing DOMEventStream._emit
from:
 def _emit(self):
 """ Fallback replacement for getEvent() that emits
 the events that _slurp() read previously.
 """
 rc = self.pulldom.firstEvent[1][0]
 self.pulldom.firstEvent[1] = self.pulldom.firstEvent[1][1]
 return rc
To the following:
 def _emit(self):
 """ Fallback replacement for getEvent() that emits
 the events that _slurp() read previously.
 """
 if self.pulldom.firstEvent[1] is None:
 return None
 rc = self.pulldom.firstEvent[1][0]
 self.pulldom.firstEvent[1] = self.pulldom.firstEvent[1][1]
 return rc
*Seems* to work.
History
Date User Action Args
2008年09月12日 00:31:17nrileysetspambayes_score: 0.356344 -> 0.0
2008年06月06日 02:44:12leosotosetspambayes_score: 0.356344 -> 0.356344
messageid: <1212720252.24.0.543432630334.issue1047@psf.upfronthosting.co.za>
2008年06月06日 02:44:12leosotosetspambayes_score: 0.356344 -> 0.356344
recipients: + leosoto
2008年06月06日 02:44:12leosotolinkissue1047 messages
2008年06月06日 02:44:12leosotocreate

Supported by Python Software Foundation,
Powered by Roundup

AltStyle によって変換されたページ (->オリジナル) /